Commit graph

76925 commits

Author SHA1 Message Date
Spandan Das
4bec95e2f6 Merge "Disable dexpreopt if optional_uses_libs does not have an impl" into main 2024-02-20 08:08:35 +00:00
Spandan Das
73f4a4a481 Merge "Revert "Revert "Create a product variable for skipping apex cont..."" into main 2024-02-20 07:53:03 +00:00
Treehugger Robot
3ce80aef7f Merge "Version LLNDK ABI dumps with VendorApiLevel" into main 2024-02-17 05:58:03 +00:00
Spandan Das
8ab28dd61d Revert "Revert "Create a product variable for skipping apex cont..."
Revert submission 2966055-revert-2964509-skip-apex-contributions-EOKWOFHENC

Reason for revert: The root cause CL has been reverted https://googleplex-android-review.git.corp.google.com/c/platform/vendor/google/build/+/26268799

Reverted changes: /q/submissionid:2966055-revert-2964509-skip-apex-contributions-EOKWOFHENC

Change-Id: I93e8f60124a09b4fba4675ac7f128ab553102bf7
2024-02-17 03:31:45 +00:00
Treehugger Robot
3e48d693f4 Merge "Revert "Create a product variable for skipping apex contribution..."" into main 2024-02-17 02:24:02 +00:00
Hsin-Yi Chen
53eb289ad0 Merge "Separate LLNDK ABI diff reports from the other variants" into main 2024-02-17 02:15:39 +00:00
Zi Wang
0fd4bb8c70 Merge "Add jarjar_prefix propagation support for aconfig_declarations_group module type" into main 2024-02-17 01:24:09 +00:00
Jihoon Kang
3801a965d5 Revert "Create a product variable for skipping apex contribution..."
Revert submission 2964509-skip-apex-contributions

Reason for revert: 325666427

Reverted changes: /q/submissionid:2964509-skip-apex-contributions

Change-Id: I510e81c8e06803dc014c9f04c3e357065aa19ce5
2024-02-16 23:25:06 +00:00
Jihoon Kang
03d014ff2b Add jarjar_prefix propagation support for aconfig_declarations_group module type
jarjar_prefix propagation logic currently depends on the type of the
providers of the dependencies, thus the logic needs to be updated when a
new provider is added. Since `aconfig_declarations_group` module type
utilizes its custom provider "CodegenInfoProvider", this change adds
jarjar_prefix propagation support for this provider.

Test: Set aconfig_declaration module's exportable property to true && m framework-minus-apex and inspect if "repackaged-jarjar" subdir exists in outdir
Bug: 310504781
Change-Id: I1689027d7810687a53ec34b9cfda479806f2ec87
2024-02-16 22:22:18 +00:00
Spandan Das
0727ba76b1 Disable dexpreopt if optional_uses_libs does not have an impl
At ToT, an optional_uses_libs is not added to the build time CLC if it
does not exist in the tree. One edge case here is
java_sdk_library_import, which might exist in the tree, but without an
implementation. This cause issues during analysis when we try to verify
the correctness of the build time CLC.

This CL disables dexpreopt if a dependency does not have an
implementation. To limit inadvertent side effects, this is restricted to
java_sdk_library(_import) module types. (more precisely, it is restricted
to java_sdk_library_import, since the source module type will always
have an impl)

Bug: 315802285
Test: Added a unit test
Test: m nothing
Test: printf debugging in internal main, verified that this CL does not
disable dexpreopt on any android app inadvertently

Change-Id: I173fc2f3ff654fe4091e9a43322164afd3222ee7
2024-02-16 18:00:27 +00:00
Joonhun Shin
af9fc549ca Merge "Revert "Make building Rust targets faster in eng builds"" into main 2024-02-16 07:56:01 +00:00
Joonhun Shin
fad3e69d7f Revert "Make building Rust targets faster in eng builds"
This reverts commit 6146cf4b98.

Reason for revert: <b/325547632>

Change-Id: Ifd3619c5db5b989edb4aa2c37f85e5cd88d0c633
2024-02-16 07:26:14 +00:00
Inseob Kim
f617e18741 Merge "Fix characteristic rro for overridden packages" into main 2024-02-16 01:41:48 +00:00
Chris Wailes
3fae67a32d Merge "Make building Rust targets faster in eng builds" into main 2024-02-15 23:12:27 +00:00
Paul Duffin
a0f0bdbced Merge "Revert^3 "Integrate Rust-specific System Properties into rules generation."" into main 2024-02-15 12:45:47 +00:00
Paul Duffin
2766baa922 Revert^3 "Integrate Rust-specific System Properties into rules generation."
This reverts commit ac0c87311d.

Reason for revert: breaking the same bug, b/323833345 as before

Change-Id: I474c032148f22c4b98f7adf23be61807fa0500a0
2024-02-15 11:54:17 +00:00
Andrew Walbran
e38e2c0071 Merge "Revert^2 "Integrate Rust-specific System Properties into rules generation."" into main 2024-02-15 10:31:49 +00:00
Spandan Das
90db03c007 Merge "Create a product variable for skipping apex contribution contents" into main 2024-02-15 08:10:57 +00:00
Spandan Das
68a6e29ed5 Create a product variable for skipping apex contribution contents
This denylist will be used to ignore the prebuilt google apexes listed
in apex_contributions of vendor/google/build when building aosp products
in next.

Test: go build ./android
Bug: 308187268
Change-Id: Ib2c018a2aeda5578cf3f1a6a56253bf84850ba5f
Merged-In: Ib2c018a2aeda5578cf3f1a6a56253bf84850ba5f
2024-02-15 01:39:26 +00:00
Treehugger Robot
e4c98ae235 Merge changes I42eb64d3,I93d73757 into main
* changes:
  Enable droidstubs to depend on aconfig_declarations_group module type
  Introduce module type aconfig_declarations_group
2024-02-14 22:14:30 +00:00
LaMont Jones
b45200bd0b Merge changes from topic "is_stubs_module" into main
* changes:
  Improve determination whether to propagate JarJarProvider
  Introduce library property is_stubs_module
2024-02-14 21:38:20 +00:00
Ronald Braunstein
e48bcc2aaa Merge "Export teams even when module disabled." into main 2024-02-14 20:52:03 +00:00
Colin Cross
308d64ed72 Merge "Always use aapt2 --no-static-lib-packages" into main 2024-02-14 20:01:25 +00:00
Jihoon Kang
38e4f258f7 Enable droidstubs to depend on aconfig_declarations_group module type
This change enabled aconfig_declarations_group module type to be added
as `aconfig_declarations` property of droidstubs module. Similar to
aconfig_declrations module, the aconfig_declarations_group module
provides the intermediate cache files of the aconfig_declarations
modules of the listed codegen modules to droidstubs module.

Test: m nothing --no-skip-soong-tests
Change-Id: I42eb64d3ab65e679ea733c5bb98833971e49a8e8
2024-02-14 18:52:51 +00:00
Jihoon Kang
2a43e56b5f Introduce module type aconfig_declarations_group
In order to easily manage aconfig_declarations modules and their
corresponding codegen modules, this change introduces a new module type
`aconfig_declarations_group`. The module enables listing codegen modules
by language, and correctly depend on the desired output files using
appropriate tags.

e.g. for an aconfig_declarations_group module "some_group", the rdeps of
the module can:
- gather all intermediates cache files of the aconfig_declarations with
  ":some_group" tag.
- gather generated srcjar files of the listed java_aconfig_library
  modules with ":some_group{.srcjars}" tag.

Output tag support for cc modules and rust modules will be added in
future changes.

Test: m nothing --no-skip-soong-tests
Bug: 320492079
Change-Id: I93d737577f8d00198ed91048dd6e81ef238193cb
2024-02-14 18:52:31 +00:00
Andrew Walbran
ac0c87311d Revert^2 "Integrate Rust-specific System Properties into rules generation."
This reverts commit be3ea4f149.

Reason for revert: Reland

Change-Id: Ic003c52a1477da9a6a70b82e4d4ae4a55edc584f
2024-02-14 10:25:55 +00:00
Inseob Kim
5b90d3a703 Fix characteristic rro for overridden packages
Overridden packages can have different package names. This change reads
output APKs to parse package name, instead of manifest xml.

Bug: 325011777
Test: boot and idmap2 dump
Change-Id: I748b9db8bd6282d7f3a1478cf94b21580c7683e7
2024-02-14 16:55:33 +09:00
Ronald Braunstein
bb08413605 Export teams even when module disabled.
Some modules only build for arm, but the CI build producing the
all_teams proto artifact is building for X86 and the module was getting
left out.

The fix was to stop checking the Enabled() flag.

Test: m all_teams ; # inspected proto
Fixes: 325054164
Change-Id: I607c289f3ba47c2ddf6324ccff144712d782044d
2024-02-13 18:33:22 -08:00
Treehugger Robot
d8bab3758b Merge "Skip passing "--product default" to aapt2" into main 2024-02-14 01:20:52 +00:00
LaMont Jones
63683e40c4 Improve determination whether to propagate JarJarProvider
Add more explicit checks to not propagate JarJarProvider when we will be
linking against stubs.

Bug: b/310504781
Test: treehugger
Merged-In: I3219d0bf7e84a386b16b248314f11b4e9edcd0fa
Change-Id: I3219d0bf7e84a386b16b248314f11b4e9edcd0fa
2024-02-13 17:04:17 -08:00
Jihoon Kang
fe914ed17f Introduce library property is_stubs_module
is_stubs_module property signifies whether the module compiles stubs or
not. The information is propagated to the reverse dependencies of the
java_library/java_sdk_library modules via JavaInfoProvider as
StubsLinkType, a ternary state that provides information about whether
the provided jars are compilation of stubs or implementation, or
unknown.

When java_sdk_library sets StubsLinkType, its state is Unknown as the
decision of providing stubs vs implementation jar differs by the reverse
dependency.

Note that this CL does NOT propagate the property up to its reverse
dependencies. This will be done in follow up CLs.

Test: m nothing
Bug: 310504781
Merged-In: Ic81488dbd1c9af1b5d31a33e5e9441d9f1416dbe
Change-Id: Ic81488dbd1c9af1b5d31a33e5e9441d9f1416dbe
2024-02-13 16:56:38 -08:00
Colin Cross
7c4dc5d185 Always use aapt2 --no-static-lib-packages
--no-static-lib-packages was removed when compiling libraries with
use_resource_processor: true enabled, but that caused problems resolving
attributes of styleables.  androidx.preference declares the "icon"
attribute inside a <declare-styleable>, but doesn't give it a format.
aapt2 refuses to create a new attribute for this case (b/131100106),
but without --no-static-lib-packages aapt2 can resolve the attribute
from the one defined in androidx.appcompat.

Bug: 294256649
Test: builds
Change-Id: I13661be83ba6501b0c2b1af8e632f260f405a370
2024-02-13 14:29:45 -08:00
Yisroel Forta
9923e80b3d Merge "Add profiling to skip strict updatability allowlist" into main 2024-02-13 17:04:12 +00:00
Ivan Lozano
c2d4959bb4 Merge "rust: Re-enable host address sanitizer." into main 2024-02-13 16:34:42 +00:00
Yisroel Forta
154796c0e2 Add profiling to skip strict updatability allowlist
Test: presubmit
Bug: b/293957254
Change-Id: I9d53f3237ff5f076b8299138e02d991f8881e06f
2024-02-13 14:12:11 +00:00
Spandan Das
2dc86ebd3e Merge "Restrict verify_overlaps to pre S modules" into main 2024-02-13 10:53:23 +00:00
Jihoon Kang
a0ccab683b Merge "Add environment variable UNBUNDLED_BUILD_TARGET_SDK_WITH_DESSERT_SHA" into main 2024-02-13 04:27:21 +00:00
Inseob Kim
47074225df Merge "Revert^2 "Remove unused ToTSepolicyVersion"" into main 2024-02-13 04:02:35 +00:00
Inseob Kim
10af6edc52 Skip passing "--product default" to aapt2
Because
1) it has no effect.
2) it will simplify build commands, which will minimize differences
   among targets using generate_product_characteristics_rro

Bug: 322932641
Test: TH
Change-Id: I16afae597038da7489989483f8c926916d207df5
2024-02-13 12:56:46 +09:00
Spandan Das
38c64f62cf Restrict verify_overlaps to pre S modules
The runtime in S and above does not have the same constraints that
require the hiddenapi flags to be generated in a monolithic manner.
This CL restricts the verify_overlaps to pre S modules. This will
filter out hiddenapi signature discrepancies that do not require
any action.

Test: verify_overlaps diff with this change https://diff.googleplex.com/#key=xxB0ky93hZRn
Test: presubmits
Bug: 313672880

Change-Id: Ie626a6779fc924563bec90b6c1ab0c7e8b4b23c2
2024-02-13 02:33:12 +00:00
Anas Sulaiman
64f5b207eb Merge "Fix non-deterministic output for merge_zips" into main 2024-02-13 02:20:53 +00:00
Inseob Kim
dae1375433 Revert^2 "Remove unused ToTSepolicyVersion"
a1448e072e

Change-Id: I728d0633718669fb57877e7440dedf49ab980a00
2024-02-13 02:19:24 +00:00
Kiyoung Kim
997951dd96 Merge "Do not dump BOARD_VNDK_VERSION" into main 2024-02-13 00:51:53 +00:00
Treehugger Robot
c521446153 Merge "[Ravenwood] Install transitive JNI libraries too" into main 2024-02-12 22:34:39 +00:00
Anas Sulaiman
437e9470c0 Fix non-deterministic output for merge_zips
A map iteration was causing a non-deterministic order
in output entries. The default behaviour is to preserve
the same order of the input zips, which is necessary
to ensure a deterministic output for deterministic inputs.

Bug: b/322788229
Test: Ran a couple of builds and confirmed no cache misses from
the output of merge_zips.

Change-Id: I3217e6887ab108d213a290b59da5b33d51b8241f
2024-02-12 22:00:55 +00:00
Jihoon Kang
842b999a53 Add environment variable UNBUNDLED_BUILD_TARGET_SDK_WITH_DESSERT_SHA
UNBUNDLED_BUILD_TARGET_SDK_WITH_DESSERT_SHA enables user to specify
${codename}.${sha} as min_sdk_version and target_sdk_version in order to
support mainline train building into android build.

Test: TH
Bug: 295905124
Change-Id: I032d464aaa7314520f98b8eafa53d962940075ce
2024-02-12 21:12:58 +00:00
Colin Cross
a82de712b3 Merge changes from topic "revert-2952265-revert-2925209-KVPWEBRQHT-BBCOVJBOVF" into main
* changes:
  Remove fdoProfileMutator
  Convert AFDO mutators to TransitionMutator
2024-02-12 19:31:00 +00:00
Ivan Lozano
357433ae73 rust: Re-enable host address sanitizer.
Our toolchain supports a flag "-Z external-clangrt=true" which prevents
rustc from emitting a missing dependency to librust-dev_rt. Instead, we
link in libclang_rt.

Bug: 304507701
Bug: 324826914
Test: SANITIZE_HOST=address m aconfig
Change-Id: I8020c550b7a922c80620f61c22e01848a4f4a349
2024-02-12 14:16:26 -05:00
Yu Liu
b882375fe0 Merge "Only link the profile extras lib for device variant." into main 2024-02-12 18:12:14 +00:00
Stephen Hines
833a00e36e Merge "Allow clippy::unnecessary_fallible_conversions" into main 2024-02-12 17:32:27 +00:00