blob: 96dad3c61be016a5f968cc76ba3907342eb8fe11 [file] [log] [blame]
"""
Build flag definitions.
"""
# Copyright (C) 2023 The Android Open Source Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This file defines the build system flags that can be set based on the
# release configuration. If at all possible, use aconfig flags instead.
# This is for things that must be decided at compile time.
load(
"//build/make/core/release_config.scl",
"ALL",
"PRODUCT", # buildifier: disable=load
"SYSTEM", # buildifier: disable=load
"SYSTEM_EXT", # buildifier: disable=load
"VENDOR", # buildifier: disable=load
"flag",
)
# Flags should be alphabetical by flag name to reduce merge conflifcts
flags = [
# The default permission for all flags
flag("RELEASE_ACONFIG_FLAG_DEFAULT_PERMISSION", ALL, "READ_WRITE"),
# The aconfig_value_set soong module(s) to use to set aconfig values.
# If multiple values are provided, then they will be used in the order they
# were added: the last value for a flag is the final value.
flag("RELEASE_ACONFIG_VALUE_SETS", ALL, None, appends = True),
# Enables the use of the unfrozen versions of AIDL interfaces.
# When this is `False` the libraries of the latest unfrozen version of a
# stable interface will behave like the last frozen version.
# When this is `True` the libraries behave like the lastest unfrozen version like
# they always have.
flag("RELEASE_AIDL_USE_UNFROZEN", ALL, True),
# jars need to be excluded from Apex Boot Jars for targets with mainline prebuilts enabled.
flag("RELEASE_APEX_BOOT_JARS_PREBUILT_EXCLUDED_LIST", ALL, ""),
# Move User avatar picker from SettingsLib to preinstalled app.
flag("RELEASE_AVATAR_PICKER_APP", ALL, False),
# Enables acces to the AVF APIs to pre-installed apps.
flag("RELEASE_AVF_ALLOW_PREINSTALLED_APPS", SYSTEM, False),
# Enables assigning hardware devices to the guest VMs.
# If this flag is enabled, then RELEASE_AVF_ENABLE_MICRODROID_VENDOR_MODULES
# must also be enabled.
flag("RELEASE_AVF_ENABLE_DEVICE_ASSIGNMENT", ALL, False),
# Enables new DICE functionality in Microdroid VMs.
flag("RELEASE_AVF_ENABLE_DICE_CHANGES", ALL, False),
# Enables new llPvm functionality in Microdroid VMs.
flag("RELEASE_AVF_ENABLE_LLPVM_CHANGES", ALL, False),
# Enables running multiple payloads in the same Microdroid VM instance.
flag("RELEASE_AVF_ENABLE_MULTI_TENANT_MICRODROID_VM", SYSTEM, False),
# Enables pVM remote attestation in Microdroid VM.
flag("RELEASE_AVF_ENABLE_REMOTE_ATTESTATION", ALL, False),
# Enables loading vendor modules (both kernel & userspace) in Microdroid VM.
flag("RELEASE_AVF_ENABLE_VENDOR_MODULES", ALL, False),
# Enables Virtual Cpufreq support in Microdroid VM.
flag("RELEASE_AVF_ENABLE_VIRT_CPUFREQ", ALL, False),
# Specify which Microdroid kernel version to use for Microdroid VMs.
flag("RELEASE_AVF_MICRODROID_KERNEL_VERSION", SYSTEM, None),
# Enable running custom VMs with paravirtualized devices.
flag("RELEASE_AVF_SUPPORT_CUSTOM_VM_WITH_PARAVIRTUALIZED_DEVICES", ALL, False),
# If enabled, DeathRecipient is not strongly referenced from JNI.
flag("RELEASE_BINDER_DEATH_RECIPIENT_WEAK_FROM_JNI", ALL, False),
# The API level of current vendor API surface. It has YYYYMM format.
flag("RELEASE_BOARD_API_LEVEL", ALL, ""),
# Set to True to freeze the board API level with vendor FRC
flag("RELEASE_BOARD_API_LEVEL_FROZEN", ALL, False),
# If true, then crashrecovery module is enabled as an apex
flag("RELEASE_CRASHRECOVERY_MODULE", ALL, False),
# If true, then files are moved from platform to apex
flag("RELEASE_CRASHRECOVERY_FILE_MOVE", ALL, False),
# Enable build system to create new aconfig storage files.
flag("RELEASE_CREATE_ACONFIG_STORAGE_FILE", ALL, False),
# The behavior for the tree wrt building mainline modules or using prebuilts
flag("RELEASE_DEFAULT_MODULE_BUILD_FROM_SOURCE", ALL, True),
# feature flag to deprecate VNDK
flag("RELEASE_DEPRECATE_VNDK", ALL, True),
# Enables Bluetooth Ranging Service
flag("RELEASE_HARDWARE_BLUETOOTH_RANGING_SERVICE", ALL, True),
# b/319697968: Flag to determine the dependency of hiddenapi to the stubs that contain all
# flagged apis ("everything" stubs), or to the stubs that contain only the enabled flagged
# apis ("exportable" stubs).
flag("RELEASE_HIDDEN_API_EXPORTABLE_STUBS", ALL, False),
# The version of mainline prebuilts used when prebuilts are enabled.
flag("RELEASE_MAINLINE_MODULE_PREBUILT_VERSION", ALL, "mainline_module_prebuilt_nightly"),
# If true, then files are moved from platform to apex
flag("RELEASE_MOVE_PDFRENDERER_TO_MODULE", ALL, False),
# Enables ABI monitoring of NDK libraries.
flag("RELEASE_NDK_ABI_MONITORED", ALL, False),
# Version of the emoji font file.
flag("RELEASE_PACKAGE_EMOJI_FONT_VERSION", SYSTEM, "2.042"),
# Version of the flag emoji font file.
flag("RELEASE_PACKAGE_FLAG_EMOJI_FONT_VERSION", SYSTEM, "2.034"),
# This flag will control of including Japanese variant (Hentaigana) font.
flag("RELEASE_PACKAGE_HENTAIGANA_FONT", SYSTEM, False),
# The sqlite release.
flag("RELEASE_PACKAGE_LIBSQLITE3", SYSTEM, "3420000"),
# b/292140387: Flag to switch to the new NFC apex
flag("RELEASE_PACKAGE_NFC_STACK", SYSTEM, "NfcNci"),
# Flag will control the release of the Profiling module apex.
flag("RELEASE_PACKAGE_PROFILING_MODULE", ALL, False),
# This flag will control the rollout of new versions of the SoundPicker app.
flag("RELEASE_PACKAGE_SOUND_PICKER", ALL, "SoundPicker"),
# tzdata to be installed to the system image.
flag("RELEASE_PACKAGE_TZDATA_MODULE", ALL, None),
# True for using variable font of the NotoSansCJK
flag("RELEASE_PACKAGE_VARIABLE_NOTO_SANS_CJK", SYSTEM, False),
# The name of the virtual camera package to add to the system partition.
flag("RELEASE_PACKAGE_VIRTUAL_CAMERA", SYSTEM, ""),
# The sdk extension version of this release configuration.
flag("RELEASE_PLATFORM_SDK_EXTENSION_VERSION", ALL, "7"),
# The SDK version of the platform, e.g. 34 for UDC. This should only be increased
# when the API is finalized and the codename is set to rel, not during development.
flag("RELEASE_PLATFORM_SDK_VERSION", ALL, "34"),
# Used to indicate the security patch that has been applied to the device.
# It must signify that the build includes all security patches issued up through the designated Android Public Security Bulletin.
# It must be of the form "YYYY-MM-DD" on production devices.
# It must match one of the Android Security Patch Level strings of the Public Security Bulletins.
# If there is no $PLATFORM_SECURITY_PATCH set, keep it empty.
flag("RELEASE_PLATFORM_SECURITY_PATCH", ALL, "2023-12-05"),
# The platform version.
# TODO(joeo): Remove the default here. Maybe for platform builds not having
# a version should be an error and should be allowed for unbundled builds.
# The platform version. This is the 4 letter code, e.g. UD1A, UPB1, ZP1A, etc.
flag("RELEASE_PLATFORM_VERSION", ALL, "ZP1A"),
# A comma separated list of all codenames that are in preview.
# This variable is sort of a lie for historical reasons and only
# includes codenames up to and including the currently active codename
flag("RELEASE_PLATFORM_VERSION_ALL_CODENAMES", ALL, "VanillaIceCream"),
# A comma separated list of all preview codenames the platform will accept apps built against
flag("RELEASE_PLATFORM_VERSION_ALL_PREVIEW_CODENAMES", ALL, "VanillaIceCream"),
# Set to REL for production platform builds, otherwise the codename string,
# e.g. UpsideDownCake or VanillaIceCream
flag("RELEASE_PLATFORM_VERSION_CODENAME", ALL, "VanillaIceCream"),
# A comma separated list of all known codenames.
# For REL (finalized) configurations, it has to only contain finalized codenames.
flag("RELEASE_PLATFORM_VERSION_KNOWN_CODENAMES", ALL, "Base,Base11,Cupcake,Donut,Eclair,Eclair01,EclairMr1,Froyo,Gingerbread,GingerbreadMr1,Honeycomb,HoneycombMr1,HoneycombMr2,IceCreamSandwich,IceCreamSandwichMr1,JellyBean,JellyBeanMr1,JellyBeanMr2,Kitkat,KitkatWatch,Lollipop,LollipopMr1,M,N,NMr1,O,OMr1,P,Q,R,S,Sv2,Tiramisu,UpsideDownCake,VanillaIceCream"),
# The last stable version name of the platform that was released. During
# development, this stays at that previous version, while the codename indicates
# further work based on the previous version.
flag("RELEASE_PLATFORM_VERSION_LAST_STABLE", ALL, "14"),
# The PLATFORM_VNDK_VERSION will be set to this version when the
# PLATFORM_VERSION_CODENAME is REL. This VNDK version flag will be removed
# when the VNDK is deprecated
flag("RELEASE_PLATFORM_VNDK_VERSION", ALL, "35"),
# feature flag for removing legacy emoji font from system image.
flag("RELEASE_REMOVE_LEGACY_EMOJI_FONT", SYSTEM, False),
# Ignore /data/data relabelling in libselinux.
flag("RELEASE_SELINUX_DATA_DATA_IGNORE", ALL, False),
# feature flag for a new API to open declared passthrough HAL
flag("RELEASE_SM_OPEN_DECLARED_PASSTHROUGH_HAL", ALL, False),
# flag to enable the unlocked-only storage API's SEPolicy rules
flag("RELEASE_UNLOCKED_STORAGE_API", ALL, False),
# feature flag for enabling use_resource_processor: true by default
flag("RELEASE_USE_RESOURCE_PROCESSOR_BY_DEFAULT", ALL, False),
# b/318717084 - enable the WebViewBootstrap mainline module
flag("RELEASE_USE_WEBVIEW_BOOTSTRAP_MODULE", ALL, False),
]
# Flags should be alphabetical by flag name to reduce merge conflifcts