forked from openkylin/platform_build
Merge "Support vendor bootconfig creation"
This commit is contained in:
commit
fd4f3c4c63
|
@ -1014,6 +1014,15 @@ ifdef INTERNAL_KERNEL_CMDLINE
|
|||
INTERNAL_VENDOR_BOOTIMAGE_ARGS += --vendor_cmdline "$(INTERNAL_KERNEL_CMDLINE)"
|
||||
endif
|
||||
|
||||
ifdef INTERNAL_BOOTCONFIG
|
||||
INTERNAL_VENDOR_BOOTCONFIG_TARGET := $(PRODUCT_OUT)/vendor-bootconfig.img
|
||||
$(INTERNAL_VENDOR_BOOTCONFIG_TARGET):
|
||||
rm -f $@
|
||||
$(foreach param,$(INTERNAL_BOOTCONFIG), \
|
||||
printf "%s\n" $(param) >> $@;)
|
||||
INTERNAL_VENDOR_BOOTIMAGE_ARGS += --vendor_bootconfig $(INTERNAL_VENDOR_BOOTCONFIG_TARGET)
|
||||
endif
|
||||
|
||||
# $(1): Build target name
|
||||
# $(2): Staging dir to be compressed
|
||||
# $(3): Build dependencies
|
||||
|
@ -1061,7 +1070,7 @@ $(foreach vendor_ramdisk_fragment,$(BOARD_VENDOR_RAMDISK_FRAGMENTS), \
|
|||
|
||||
INSTALLED_VENDOR_BOOTIMAGE_TARGET := $(PRODUCT_OUT)/vendor_boot.img
|
||||
$(INSTALLED_VENDOR_BOOTIMAGE_TARGET): $(MKBOOTIMG) $(INTERNAL_VENDOR_RAMDISK_TARGET) $(INSTALLED_DTBIMAGE_TARGET)
|
||||
$(INSTALLED_VENDOR_BOOTIMAGE_TARGET): $(INTERNAL_VENDOR_RAMDISK_FRAGMENT_TARGETS)
|
||||
$(INSTALLED_VENDOR_BOOTIMAGE_TARGET): $(INTERNAL_VENDOR_RAMDISK_FRAGMENT_TARGETS) $(INTERNAL_VENDOR_BOOTCONFIG_TARGET)
|
||||
ifeq ($(BOARD_AVB_ENABLE),true)
|
||||
$(INSTALLED_VENDOR_BOOTIMAGE_TARGET): $(AVBTOOL) $(BOARD_AVB_VENDOR_BOOTIMAGE_KEY_PATH)
|
||||
$(call pretty,"Target vendor_boot image: $@")
|
||||
|
@ -4794,6 +4803,9 @@ ifdef INSTALLED_VENDOR_BOOTIMAGE_TARGET
|
|||
ifdef INSTALLED_DTBIMAGE_TARGET
|
||||
cp $(INSTALLED_DTBIMAGE_TARGET) $(zip_root)/VENDOR_BOOT/dtb
|
||||
endif
|
||||
ifdef INTERNAL_VENDOR_BOOTCONFIG_TARGET
|
||||
cp $(INTERNAL_VENDOR_BOOTCONFIG_TARGET) $(zip_root)/VENDOR_BOOT/vendor_bootconfig
|
||||
endif
|
||||
ifdef BOARD_KERNEL_BASE
|
||||
echo "$(BOARD_KERNEL_BASE)" > $(zip_root)/VENDOR_BOOT/base
|
||||
endif
|
||||
|
|
|
@ -25,6 +25,7 @@ _board_strip_readonly_list += BOARD_EGL_CFG
|
|||
_board_strip_readonly_list += BOARD_HAVE_BLUETOOTH
|
||||
_board_strip_readonly_list += BOARD_INSTALLER_CMDLINE
|
||||
_board_strip_readonly_list += BOARD_KERNEL_CMDLINE
|
||||
_board_strip_readonly_list += BOARD_BOOTCONFIG
|
||||
_board_strip_readonly_list += BOARD_KERNEL_BASE
|
||||
_board_strip_readonly_list += BOARD_USES_GENERIC_AUDIO
|
||||
_board_strip_readonly_list += BOARD_USES_RECOVERY_AS_BOOT
|
||||
|
@ -222,6 +223,7 @@ endif
|
|||
.KATI_READONLY := $(_board_strip_readonly_list)
|
||||
|
||||
INTERNAL_KERNEL_CMDLINE := $(BOARD_KERNEL_CMDLINE)
|
||||
INTERNAL_BOOTCONFIG := $(BOARD_BOOTCONFIG)
|
||||
|
||||
ifneq ($(filter %64,$(TARGET_ARCH)),)
|
||||
TARGET_IS_64_BIT := true
|
||||
|
|
|
@ -1691,6 +1691,11 @@ def _BuildVendorBootImage(sourcedir, info_dict=None):
|
|||
cmd.extend(["--vendor_ramdisk", ramdisk_img.name])
|
||||
cmd.extend(["--vendor_boot", img.name])
|
||||
|
||||
fn = os.path.join(sourcedir, "vendor_bootconfig")
|
||||
if os.access(fn, os.F_OK):
|
||||
cmd.append("--vendor_bootconfig")
|
||||
cmd.append(fn)
|
||||
|
||||
ramdisk_fragment_imgs = []
|
||||
fn = os.path.join(sourcedir, "vendor_ramdisk_fragments")
|
||||
if os.access(fn, os.F_OK):
|
||||
|
|
Loading…
Reference in New Issue