In the Bazel rule, the actual AndroidManifest.xml file isn't available
in the providers of the android_binary dependency. And for good reason,
we should also rely on aapt2 to dump the manifest contents from the
final packaged APK anyway, but this auto gen script doesn't support
reading the output of aapt2 dump.
This CL adds a simple reader of the output of `aapt2 dump xmltree`, and
enabled if the xmltree content is passed to this tool instead of
AndroidManifest.xml.
Also fixup auto_gen_test_config_test.py. The test was completely failing.
Test: atest auto_gen_test_config_test
Test: presubmits
Change-Id: I7fecd927d0ed7847b6463d964b3698f4164b0177
The framework_partition_set would be generated from
framework_item_list and we should respect this partition
set while merging META/ab_partitions.txt.
This is to handle the case when we use a complete merged
target files package as the framework-target-files, where
its ab_partitions.txt may have non-framework partitions.
So we need to filter them out to prevent from the merged
meta file has some partitions that don't exist.
Test: merge_target_files &&
add_img_to_target_files &&
img_from_target_files &&
flash device
Bug: 300193612
Change-Id: I0a76d706a20dcaffa2533278db7383563f03ec02
This script has the following functionality:
1. Sets up the `out` symlink to point to a default location on disk
2. Copies RBE binaries outside Cog (temporary fix for build stall problem) - b/289391270
3. Exports ANDROID_BUILD_ENVIRONMENT_CONFIG variable to point to googler-cog.json file. This file will be available in aosp-main-with-phones and goog/main and downstream branches.
TESTED=ran the script within and outside the Cog workspace to test it.
Bug: b/295053716
Change-Id: I59cd6d2d5f954be6f7e4ecd7d64de1e63e51b72e
It has been mandatory since Android 11 (rvc) launching devices. Now we
can enable the product variants by default to all devices.
Bug: 300371698
Test: TH
Change-Id: I6b2d2e8e105ca35c38db8132486b1cb3bdbab40f
Reading value from DeviceConfig may fail if the provider is not ready.
Since DeciceConfig, and Settings class are static wrapper on top of
the provider, it won't cause the instance initialization issue.
Thus when the issue happens it means the provider is not initialized.
Test: atest aconfig.test.java and manually make a change in the
framework and check the exception message
Bug: 299471646
Change-Id: Ic08d7a9cd32a8810a7274b6d93c249abccb50b9e
Revert submission 2742398-cas-apex
Reason for revert: culprit for flake b/300311777, verified with go/abtd with 15 runs to make sure the flake is gone https://android-build.googleplex.com/builds/abtd/run/L46500000963034919
Bug:300311777
Change-Id: I2b566413ac1869f9bf3e974da7d84662047e436a
The newly added mainline_module_prebuilt_nightly and mainline_module_prebuilt_monthly_release are possible values for RELEASE_MAINLINE_MODULE_PREBUILT_VERSION (build flag in trunk stable). By adding these in BLUEPRINT_INCLUDE_TAGS_ALLOWLIST, we would be able to choose mainline modules prebuilts (apks) based on release config.
Bug: 294969202
Test: DEFAULT_MODULE_BUILD_FROM_SOURCE=false m (with 2 versions of apks, different blueprint_package_includes)
Change-Id: Ifcc49e5499d4659b73179fff715945cd2e3ca4fa
Because of a bug in metalava [1], the flag constants are incorrectly
considered not-hidden when metalava generates the API signature files.
This means the FLAG_ constant name will be used, instead of the FLAG_
constant value, which is what we want.
While waiting for b/300211291 to be fixed, explicitly mark the FLAG_
constants as hidden (and keep marking the classes as such).
This CL can be reverted when b/300211291 is fixed.
1. Item.isHiddenOrRemoved does not check if its parent item is hidden,
tracked in b/300211291
Bug: 297881670
Test: atest aconfig.test aconfig.test.java
Change-Id: I05de8344ccb424bee51c39f9609489ad312397ce
Support LOCAL_JAVA_LANGUAGE_VERSION := 11 or 17 and match the default value of 17 used
in Soong.
Bug: 298613711
Bug: 299937334
Test: m javac-check
Change-Id: I19aa24cc5197ab0e6cb03361124c36ce3e316810
VNDK will be frozen only if the VNDK version is less than or equal to
34. Otherwize do not freeze the VNDK libraries.
Bug: 297542516
Bug: 299867815
Test: lunch cf_x86_64_phone-next-userdebug; m
Change-Id: Icdd288f65c5f7bdb5b4899c8e96820c2a147a011
Removing this flag as --apply-vbmeta should only be used for root vbmeta
partitions.
Test: m fastboot_info, fastboot flashall
Bug: 299440104
Change-Id: I4910008635b16c4f4194ebd45da26bd1a8875fc1
This reverts commit c0e8ffea41.
Reason for revert: The detected build breakage was unrelated to the aconfig change. Details in b/297881670#comment11.
Change-Id: Ia32bc2e796ed3de7fa049c2c2db340f4325a2853
This reverts commit 379e09d157.
Reason for revert: Seems to have broken the build. Reverting while investigating.
Change-Id: I37c9a065853ef07b1f1c18355205a2f49dd816c4
Improve performance slightly: remove unnecessary clone operations, or
use references where a new object is not needed.
Bug: 283910447
Test: atest aconfig.test
Change-Id: I75205ffa1723dd2654039baac882c225d2653c86
Flagged APIs are annotated using `@FlaggedApi(Flags.FLAG_NAME)`, where
Flags.FLAG_NAME was auto-generated by aconfig.
When metalava generates an API signature file, it can either
a) insert the value of the constant ("com.foo.bar.flag_name"), or
b) insert the name of the constant (FLAG.NAME)
In the case of @FlaggedApi, we want a). This requires that
x) metlava has access to the definition of the constant while generating the API signature file, and
y) the constant is not part of the API surface of the API signature file
x) is handled by the build system, y) is handled by the aconfig code
generation.
This CL @hide:s all generated Java code, to make sure it is accessible
within the platform, but never part of any API surface.
Bug: 297881670
Test: atest aconfig.test aconfig.test.java
Change-Id: I328ed1a652a4e5e293f2f4b11f916d29fc2fbcbd
This is to check if unknown file context labels are used in APEX. The
reason why this is done in Makefile is to cover vendor-specific SE
policy and prebuilt APEXes. Note that there's already a validation check
when building APEXes (in Soong), which only checks the generic rules,
not vendor-specific.
Bug: 299391194
Test: atest apex_sepolicy_tests_test
Test: m
Change-Id: I4378b7530e8433d2bf188db95cb5bf791e3bf778