Merge "16k: Add 16K variant kernel/ramdisk build targets" am: c179330edb
am: 233236fa17
Original change: https://android-review.googlesource.com/c/platform/build/+/2595672 Change-Id: If6ae27053c6866ef9404e3546712b63085d070fd Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
commit
4552dd8a21
2 changed files with 38 additions and 0 deletions
|
@ -1001,6 +1001,42 @@ $(eval $(call declare-0p-target,$(INSTALLED_FILES_JSON_RAMDISK)))
|
|||
|
||||
BUILT_RAMDISK_TARGET := $(PRODUCT_OUT)/ramdisk.img
|
||||
|
||||
|
||||
ifneq ($(BOARD_KERNEL_MODULES_16K),)
|
||||
|
||||
TARGET_OUT_RAMDISK_16K := $(PRODUCT_OUT)/ramdisk_16k
|
||||
BUILT_RAMDISK_16K_TARGET := $(PRODUCT_OUT)/ramdisk_16k.img
|
||||
RAMDISK_16K_STAGING_DIR := $(call intermediates-dir-for,PACKAGING,depmod_ramdisk_16k)
|
||||
|
||||
$(BUILT_RAMDISK_16K_TARGET): $(DEPMOD) $(MKBOOTFS)
|
||||
$(BUILT_RAMDISK_16K_TARGET): $(call copy-many-files,$(foreach file,$(BOARD_KERNEL_MODULES_16K),$(file):$(RAMDISK_16K_STAGING_DIR)/lib/modules/0.0/$(notdir $(file))))
|
||||
$(DEPMOD) -b $(RAMDISK_16K_STAGING_DIR) 0.0
|
||||
for MODULE in $(BOARD_KERNEL_MODULES_16K); do \
|
||||
basename $$MODULE >> $(RAMDISK_16K_STAGING_DIR)/lib/modules/0.0/modules.load ; \
|
||||
done;
|
||||
mkdir -p $(TARGET_OUT_RAMDISK_16K)/lib
|
||||
rm -rf $(TARGET_OUT_RAMDISK_16K)/lib/modules
|
||||
cp -r $(RAMDISK_16K_STAGING_DIR)/lib/modules/0.0 $(TARGET_OUT_RAMDISK_16K)/lib/modules
|
||||
$(MKBOOTFS) $(TARGET_OUT_RAMDISK_16K) > $@
|
||||
|
||||
# Builds a ramdisk using modules defined in BOARD_KERNEL_MODULES_16K
|
||||
ramdisk_16k: $(BUILT_RAMDISK_16K_TARGET)
|
||||
.PHONY: ramdisk_16k
|
||||
|
||||
endif
|
||||
|
||||
ifneq ($(BOARD_KERNEL_PATH_16K),)
|
||||
BUILT_KERNEL_16K_TARGET := $(PRODUCT_OUT)/kernel_16k
|
||||
|
||||
$(eval $(call copy-one-file,$(BOARD_KERNEL_PATH_16K),$(BUILT_KERNEL_16K_TARGET)))
|
||||
|
||||
# Copies BOARD_KERNEL_PATH_16K to output directory as is
|
||||
kernel_16k: $(BUILT_KERNEL_16K_TARGET)
|
||||
.PHONY: kernel_16k
|
||||
|
||||
endif
|
||||
|
||||
|
||||
ifeq ($(BOARD_RAMDISK_USE_LZ4),true)
|
||||
# -l enables the legacy format used by the Linux kernel
|
||||
COMPRESSION_COMMAND_DEPS := $(LZ4)
|
||||
|
|
|
@ -1810,6 +1810,8 @@ else ifeq ($(TARGET_BUILD_UNBUNDLED),$(TARGET_BUILD_UNBUNDLED_IMAGE))
|
|||
$(INTERNAL_OTA_PACKAGE_TARGET) \
|
||||
$(INTERNAL_OTA_METADATA) \
|
||||
$(INTERNAL_OTA_PARTIAL_PACKAGE_TARGET) \
|
||||
$(BUILT_RAMDISK_16K_TARGET) \
|
||||
$(BUILT_KERNEL_16K_TARGET) \
|
||||
$(INTERNAL_OTA_RETROFIT_DYNAMIC_PARTITIONS_PACKAGE_TARGET) \
|
||||
$(SYMBOLS_ZIP) \
|
||||
$(SYMBOLS_MAPPING) \
|
||||
|
|
Loading…
Reference in a new issue