Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4b6b2003 authored by Steve Muckle's avatar Steve Muckle
Browse files

generate multiple boot.img files in aosp_arm64

Generate boot.img variants with different schemes for kernel compression
(gzip, lz4, none).

The boot image is removed from vbmeta for aosp_arm64 since it is
not possible currently to store the hashes of multiple variants of a
particular image. The GKI will be verified via VTS anyway.

Also remove some emulator-specific stuff from aosp_arm64.

Bug: 151094943
Change-Id: I465ea6c98d52e839284d51b246203f6b8dfb5566
Merged-In: I465ea6c98d52e839284d51b246203f6b8dfb5566
parent 4bfa0780
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -3471,8 +3471,12 @@ $(if $(BOARD_AVB_$(call to-upper,$(1))_KEY_PATH),\
endef

ifdef INSTALLED_BOOTIMAGE_TARGET
# multiple hashes for an image are not yet supported, fortunately this
# only arises for GKI where the boot descriptor can be left out
ifeq ($(strip $(BOARD_KERNEL_BINARIES)),)
$(eval $(call check-and-set-avb-args,boot))
endif
endif

ifdef INSTALLED_VENDOR_BOOTIMAGE_TARGET
$(eval $(call check-and-set-avb-args,vendor_boot))
+5 −15
Original line number Diff line number Diff line
@@ -53,20 +53,21 @@ TARGET_2ND_CPU_VARIANT := generic
endif

include build/make/target/board/BoardConfigGsiCommon.mk
include build/make/target/board/BoardConfigEmuCommon.mk

TARGET_NO_KERNEL := false
TARGET_NO_VENDOR_BOOT := true
BOARD_USES_RECOVERY_AS_BOOT := true

BOARD_BOOTIMAGE_PARTITION_SIZE := 0x02000000
BOARD_BOOTIMAGE_PARTITION_SIZE := 0x04000000
BOARD_USERDATAIMAGE_PARTITION_SIZE := 576716800

BOARD_BOOT_HEADER_VERSION := 3
BOARD_MKBOOTIMG_ARGS += --header_version $(BOARD_BOOT_HEADER_VERSION)

# Emulator system image is going to be used as GSI and some vendor still hasn't
# cleaned up all device specific directories under root!
BOARD_KERNEL_BINARIES := kernel-5.4 kernel-5.4-gz kernel-5.4-lz4

# Some vendors still haven't cleaned up all device specific directories under
# root!

# TODO(b/111434759, b/111287060) SoC specific hacks
BOARD_ROOT_EXTRA_SYMLINKS += /vendor/lib/dsp:/dsp
@@ -76,14 +77,3 @@ BOARD_ROOT_EXTRA_SYMLINKS += /vendor/firmware_mnt:/firmware
# TODO(b/36764215): remove this setting when the generic system image
# no longer has QCOM-specific directories under /.
BOARD_SEPOLICY_DIRS += build/make/target/board/generic_arm64/sepolicy

# Wifi.
BOARD_WLAN_DEVICE           := emulator
BOARD_HOSTAPD_DRIVER        := NL80211
BOARD_WPA_SUPPLICANT_DRIVER := NL80211
BOARD_HOSTAPD_PRIVATE_LIB   := lib_driver_cmd_simulated
BOARD_WPA_SUPPLICANT_PRIVATE_LIB := lib_driver_cmd_simulated
WPA_SUPPLICANT_VERSION      := VER_0_8_X
WIFI_DRIVER_FW_PATH_PARAM   := "/dev/null"
WIFI_DRIVER_FW_PATH_STA     := "/dev/null"
WIFI_DRIVER_FW_PATH_AP      := "/dev/null"
+3 −8
Original line number Diff line number Diff line
@@ -14,15 +14,10 @@
# limitations under the License.
#

# Cuttlefish has GKI kernel prebuilts, so use those for the GKI boot.img.
ifeq ($(TARGET_PREBUILT_KERNEL),)
    LOCAL_KERNEL := device/google/cuttlefish_kernel/5.4-arm64/kernel
else
    LOCAL_KERNEL := $(TARGET_PREBUILT_KERNEL)
endif

PRODUCT_COPY_FILES += \
    $(LOCAL_KERNEL):kernel
    device/google/cuttlefish_kernel/5.4-arm64/kernel-5.4:kernel-5.4 \
    device/google/cuttlefish_kernel/5.4-arm64/kernel-5.4-gz:kernel-5.4-gz \
    device/google/cuttlefish_kernel/5.4-arm64/kernel-5.4-lz4:kernel-5.4-lz4

# Adjust the Dalvik heap to be appropriate for a tablet.
$(call inherit-product-if-exists, frameworks/base/build/tablet-dalvik-heap.mk)
+0 −2
Original line number Diff line number Diff line
@@ -14,8 +14,6 @@
# limitations under the License.
#

PRODUCT_USE_DYNAMIC_PARTITIONS := true

# The system image of aosp_arm64-userdebug is a GSI for the devices with:
# - ARM 64 bits user space
# - 64 bits binder interface