Merge "core/Makefile: Add generated product FW image" into main
diff --git a/core/Makefile b/core/Makefile
index 02b33b6..228fa72 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -768,10 +768,7 @@
# $5 partition tag
# $6 output file
define _apkcerts_write_line
-$(hide) echo -n 'name="$(1).apk" certificate="$2" private_key="$3"' >> $6
-$(if $(4), $(hide) echo -n ' compressed="$4"' >> $6)
-$(if $(5), $(hide) echo -n ' partition="$5"' >> $6)
-$(hide) echo '' >> $6
+$(hide) echo 'name="$(1).apk" certificate="$2" private_key="$3"$(if $(4), compressed="$4")$(if $(5), partition="$5")' >> $6
endef
@@ -1536,11 +1533,26 @@
ifeq ($(BOARD_16K_OTA_MOVE_VENDOR),true)
$(eval $(call copy-one-file,$(BUILT_BOOT_OTA_PACKAGE_4K),$(TARGET_OUT_VENDOR)/boot_otas/boot_ota_4k.zip))
$(eval $(call copy-one-file,$(BUILT_BOOT_OTA_PACKAGE_16K),$(TARGET_OUT_VENDOR)/boot_otas/boot_ota_16k.zip))
+
ALL_DEFAULT_INSTALLED_MODULES += $(TARGET_OUT_VENDOR)/boot_otas/boot_ota_4k.zip
ALL_DEFAULT_INSTALLED_MODULES += $(TARGET_OUT_VENDOR)/boot_otas/boot_ota_16k.zip
+
+ifneq ($(BOARD_VENDOR_KERNEL_MODULES_2ND_STAGE_16KB_MODE),)
+# Add the modules that need to be loaded in the Second Boot Stage
+# to /vendor_dlkm/lib/modules/16k-mode
+VENDOR_DLKM_16K_MODE_DIR := lib/modules/16k-mode
+$(foreach module,$(BOARD_VENDOR_KERNEL_MODULES_2ND_STAGE_16KB_MODE), \
+ $(eval $(call copy-one-file,$(TARGET_KERNEL_DIR_16K)/$(module),\
+ $(TARGET_OUT_VENDOR_DLKM)/$(VENDOR_DLKM_16K_MODE_DIR)/$(module))))
+
+ALL_DEFAULT_INSTALLED_MODULES += $(foreach module,$(BOARD_VENDOR_KERNEL_MODULES_2ND_STAGE_16KB_MODE),\
+ $(TARGET_OUT_VENDOR_DLKM)/$(VENDOR_DLKM_16K_MODE_DIR)/$(module))
+endif # BOARD_VENDOR_KERNEL_MODULES_2ND_STAGE_16KB_MODE not empty
+
else
$(eval $(call copy-one-file,$(BUILT_BOOT_OTA_PACKAGE_4K),$(TARGET_OUT)/boot_otas/boot_ota_4k.zip))
$(eval $(call copy-one-file,$(BUILT_BOOT_OTA_PACKAGE_16K),$(TARGET_OUT)/boot_otas/boot_ota_16k.zip))
+
ALL_DEFAULT_INSTALLED_MODULES += $(TARGET_OUT)/boot_otas/boot_ota_4k.zip
ALL_DEFAULT_INSTALLED_MODULES += $(TARGET_OUT)/boot_otas/boot_ota_16k.zip
endif # BOARD_16K_OTA_MOVE_VENDOR == true
diff --git a/core/android_soong_config_vars.mk b/core/android_soong_config_vars.mk
index 6fbc255..6aea680 100644
--- a/core/android_soong_config_vars.mk
+++ b/core/android_soong_config_vars.mk
@@ -325,3 +325,8 @@
# Variables for extra branches
# TODO(b/383238397): Use bootstrap_go_package to enable extra flags.
-include vendor/google/build/extra_soong_config_vars.mk
+
+# Variable for CI test packages
+ifneq ($(filter arm x86 true,$(TARGET_ARCH) $(TARGET_2ND_ARCH) $(TARGET_ENABLE_MEDIADRM_64)),)
+ $(call soong_config_set_bool,ci_tests,uses_widevine_tests, true)
+endif
diff --git a/envsetup.sh b/envsetup.sh
index 554a220..c040311 100644
--- a/envsetup.sh
+++ b/envsetup.sh
@@ -438,68 +438,6 @@
echo
}
-function lunch()
-{
- local answer
- setup_cog_env_if_needed
-
- if [[ $# -gt 1 ]]; then
- echo "usage: lunch [target]" >&2
- return 1
- fi
-
- local used_lunch_menu=0
-
- if [ "$1" ]; then
- answer=$1
- else
- print_lunch_menu
- echo "Which would you like? [aosp_cf_x86_64_phone-trunk_staging-eng]"
- echo -n "Pick from common choices above (e.g. 13) or specify your own (e.g. aosp_barbet-trunk_staging-eng): "
- read answer
- used_lunch_menu=1
- fi
-
- local selection=
-
- if [ -z "$answer" ]
- then
- selection=aosp_cf_x86_64_phone-trunk_staging-eng
- elif (echo -n $answer | grep -q -e "^[0-9][0-9]*$")
- then
- local choices=($(TARGET_BUILD_APPS= TARGET_PRODUCT= TARGET_RELEASE= TARGET_BUILD_VARIANT= _get_build_var_cached COMMON_LUNCH_CHOICES 2>/dev/null))
- if [ $answer -le ${#choices[@]} ]
- then
- # array in zsh starts from 1 instead of 0.
- if [ -n "$ZSH_VERSION" ]
- then
- selection=${choices[$(($answer))]}
- else
- selection=${choices[$(($answer-1))]}
- fi
- fi
- else
- selection=$answer
- fi
-
- export TARGET_BUILD_APPS=
-
- # This must be <product>-<release>-<variant>
- local product release variant
- # Split string on the '-' character.
- IFS="-" read -r product release variant <<< "$selection"
-
- if [[ -z "$product" ]] || [[ -z "$release" ]] || [[ -z "$variant" ]]
- then
- echo
- echo "Invalid lunch combo: $selection"
- echo "Valid combos must be of the form <product>-<release>-<variant>"
- return 1
- fi
-
- _lunch_meat $product $release $variant
-}
-
function _lunch_meat()
{
local product=$1
@@ -582,13 +520,13 @@
echo "Note that the previous interactive menu and list of hard-coded"
echo "list of curated targets has been removed. If you would like the"
echo "list of products, release configs for a particular product, or"
- echo "variants, run list_products, list_release_configs, list_variants"
+ echo "variants, run list_products list_releases or list_variants"
echo "respectively."
echo
) 1>&2
}
-function lunch2()
+function lunch()
{
if [[ $# -eq 1 && $1 = "--help" ]]; then
_lunch_usage
diff --git a/target/product/OWNERS b/target/product/OWNERS
index 48d3f2a..276c885 100644
--- a/target/product/OWNERS
+++ b/target/product/OWNERS
@@ -8,3 +8,6 @@
per-file go_defaults.mk = gkaiser@google.com, kushg@google.com, rajekumar@google.com
per-file go_defaults_512.mk = gkaiser@google.com, kushg@google.com, rajekumar@google.com
per-file go_defaults_common.mk = gkaiser@google.com, kushg@google.com, rajekumar@google.com
+
+# Translation
+per-file languages_default.mk = aapple@google.com