diff options
author | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2016-08-25 20:29:32 +0200 |
---|---|---|
committer | Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de> | 2016-08-25 20:29:32 +0200 |
commit | 4a88d296d8f17117aff867163c70092fae74ae77 (patch) | |
tree | 8c76c9f95d48f962c8be66d541ad40cbf35987a6 | |
parent | ec87bcd107d94950258a0c6ebb78bb56c09214c8 (diff) | |
download | device_samsung_i9300-4a88d296d8f17117aff867163c70092fae74ae77.zip device_samsung_i9300-4a88d296d8f17117aff867163c70092fae74ae77.tar.gz device_samsung_i9300-4a88d296d8f17117aff867163c70092fae74ae77.tar.bz2 |
add possibility to specify a custom bootimg build file for recent kernels
commented out for now
Signed-off-by: Wolfgang Wiedmeyer <wolfgit@wiedmeyer.de>
-rw-r--r-- | BoardConfig.mk | 1 | ||||
-rw-r--r-- | mkbootimg.mk | 29 |
2 files changed, 30 insertions, 0 deletions
diff --git a/BoardConfig.mk b/BoardConfig.mk index 902da90..00f0b05 100644 --- a/BoardConfig.mk +++ b/BoardConfig.mk @@ -34,6 +34,7 @@ BOARD_BLUETOOTH_BDROID_BUILDCFG_INCLUDE_DIR := device/samsung/i9300/bluetooth # Kernel TARGET_KERNEL_SOURCE := kernel/samsung/smdk4412 TARGET_KERNEL_CONFIG := cyanogenmod_i9300_defconfig +#BOARD_CUSTOM_BOOTIMG_MK := device/samsung/i9300/mkbootimg.mk # Recovery TARGET_RECOVERY_FSTAB := device/samsung/i9300/rootdir/fstab.smdk4x12 diff --git a/mkbootimg.mk b/mkbootimg.mk new file mode 100644 index 0000000..5211cce --- /dev/null +++ b/mkbootimg.mk @@ -0,0 +1,29 @@ +LOCAL_PATH := $(call my-dir) + +DTB_FILE = $(KERNEL_OUT)/arch/arm/boot/dts/exynos4412-trats2.dtb +KERNEL_ZIMG = $(KERNEL_OUT)/arch/arm/boot/zImage +KERNEL_ZIMG_DTB = $(KERNEL_ZIMG)-dtb +KERNEL_APP = $(OUT)/kernel + +$(KERNEL_ZIMG_DTB): $(KERNEL_APP) + cat $(KERNEL_ZIMG) $(DTB_FILE) > $(KERNEL_ZIMG_DTB); + rm -f $(KERNEL_APP); + cp $(KERNEL_ZIMG_DTB) $(KERNEL_APP); + +## Overload bootimg generation: Same as the original, except use appended dtb kernel +$(INSTALLED_BOOTIMAGE_TARGET): $(MKBOOTIMG) $(INTERNAL_BOOTIMAGE_FILES) $(KERNEL_ZIMG_DTB) + $(call pretty,"Target boot image: $@") + $(hide) $(MKBOOTIMG) $(INTERNAL_BOOTIMAGE_ARGS) $(BOARD_MKBOOTIMG_ARGS) --output $@ + $(hide) $(call assert-max-image-size,$@,$(BOARD_BOOTIMAGE_PARTITION_SIZE),raw) + @echo -e ${CL_CYN}"Made boot image: $@"${CL_RST} + +## Overload recoveryimg generation: Same as the original, except use appended dtb kernel +$(INSTALLED_RECOVERYIMAGE_TARGET): $(MKBOOTIMG) \ + $(recovery_ramdisk) \ + $(recovery_kernel) \ + $(KERNEL_ZIMG_DTB) + @echo -e ${CL_CYN}"----- Making recovery image ------"${CL_RST} + $(hide) $(MKBOOTIMG) $(INTERNAL_RECOVERYIMAGE_ARGS) $(BOARD_MKBOOTIMG_ARGS) --output $@ + $(hide) $(call assert-max-image-size,$@,$(BOARD_RECOVERYIMAGE_PARTITION_SIZE),raw) + @echo -e ${CL_CYN}"Made recovery image: $@"${CL_RST} + |