If the flag is set we will:
- pass --optimized-resource-shrinking to the r8 invocation
- use non final fields for the generated R classes
- not pass the aapt2 generated proguard rules, R8 will do the tracing of xml files
Bug: 325905703
Test: This is simply passing the flag through to R8, this is off by default
Change-Id: Ib2043f3201578c3bcd39c1de9a524fd78f6d795c
build/soong/sdk will use these tags to differentiate the sdk and non-sdk
contents of bootclasspath and systemserverclasspath fragments.
Test: go build ./java
Bug: 326246905
Change-Id: Ia8352c09fcbbca06988eb57153e5986801eb45a5
This change creates a "combined" filegroup module, which will contain
all api files of the subset api scopes in the followup change. In this
change, the "combined" filegroup is identical to the currently existing
last api filegroup module in that it only contains the api file /
removed api file of the specific api scope.
This change also passes the "combined" filegroup to the droidstubs
module generated from the sdk_library modules, but this currently does
not lead to any functional changes as the "combined" filegroup is
identical to the currently existing last api filegroup.
Test: m nothing --no-skip-soong-tests
Bug: 321827591
Change-Id: If73a7229f2f970f7e74cd010a8b4808dc9018344
//visibility:any_system_partition, //visibility:any_vendor_partition,
etc.
Then, if a partition visibility rule is not specificed, but the module
is installed on a non-system partition via the `vendor: true` or other
properties, the visibility rule for that partition will be added by
default.
This is so that "any_partition" doesn't imply that modules could be put
on the vendor partition when they weren't designed for that, and so that
modules that do need to go on the vendor partition don't need to specify
both vendor: true and visibility:any_vendor_partition.
Eventually, the partition properties should be deprecated, and replaced
with just these visibility rules.
Bug: 321000103
Test: go tests
Change-Id: I24dba36bbc20921941f892480bf7c050e93827c6
Bug: http://b/327307773
Newer clang rejects this flag as unsupported. It is not necessary while linking because the flag is passed as an IR feature.
Change-Id: I781afd913be7c07612196e736c3ae58773791071
We fixed the clang driver to "do the right thing" based on target api level years ago, but these manual workarounds predate that (or were copy & pasted from places that predated that). We don't need them any more.
See https://github.com/android/ndk/issues/2005 for more detail.
Change-Id: I995741b8606e389e8de8272f1cc532624516245a
Currently, the "exportable" stubs and the api files are copied to the
dist directory during SDK builds regardless of the value of the
RELEASE_HIDDEN_API_EXPORTABLE_STUBS build flag. This change modifies
such behavior that the "exportable" artifacts are copied to the dist
directory only when the RELEASE_HIDDEN_API_EXPORTABLE_STUBS flag value
is set to true.
Test: lunch aosp_arm-trunk_staging-eng && m sdk dist and inspect ninja graph to verify that the "everything" artifacts are copied to the dist directory
Bug: 330417789
Change-Id: I3b83375610eb172d7b9da7ea831a74cd427b696c
Change genrule Out to `android:"arch_variant"` for supporting
multilib variants.
Bug: 323295272
Test: go test -run TestMultilibGenruleOut
Change-Id: I102d64b45a5a2a5193f813001fc32da0d1fe9d36
This change adds the support that was added to android_app in
https://r.android.com/2854663 for android_library modules.
Implementation details:
- Move `Flags_packages` to aaptProperties, so that it can be utilized
for both android_app and android_library.
- Wrap `VisitDirectDeps` of aconfig_declarations to a function that
takes a ModuleContext as an input, so that it can be utilized in the
`GenerateAndroidBuildActions` of both android_app and android_library.
Test: m nothing --no-skip-soong-tests
Bug: 330222981
Change-Id: I8a755f5ca615c8a1651afcd2ec441fc9fbd82c61
This build flag will be used to disable the check when prebuilts are
used in internal main. For backwards compatibilty,
RELEASE_DEFAULT_MODULE_BUILD_FROM_SOURCE can also be used to disable
this check.
Test: m nothing
Bug: 328200369
Change-Id: I710811995723e75bea9de1ce5c77504f66cbcf45
This change propagates the intermediateCacheFiles generated by the
aconfig_declarations to the static rdeps that are java modules or the
rdeps that are filegroups.
Test: m nothing
Bug: 329284345
Change-Id: I02431336c1aa0378d03248f3bb6edf2f57ec3b7f
This is equivalent to specifying a dependency name different to the
package name in cargo, which some external crates do.
Bug: 308790322
Test: Built libgrpcio with aliases for protobuf
Change-Id: I2801222051fdd962460cc7f4900cec357f63b974
Bug: 329762127
Test: cd build/soong/java ; go test -run TestJavaLibHostWithStem
Test: cd build/soong/java ; go test -run TestAppStem
Test: cd build/soong/java ; go test -run TestAndroidAppImport_ArchVariants
Test: cd build/soong/java ; go test -run TestOverrideAndroidAppStem
Test: cd build/soong/java ; go test -run TestOverrideAndroidApp
Test: cd build/soong/java ; go test -run TestPackageNameOverride
Change-Id: I8fbdc82116f9a0c68121fbbeb1ef4f78f2b6fea3
This required moving to a SourceProvider for the Rust library. With the
previous approach only the first input file was being used.
Bug: 270547306
Test: Built libplatformproperties_rust, looked at output
Change-Id: I1070655abc071e099a42bc4be61cc080902e31c1
This CL is the platform_compat_config equivalent of aosp/2928483.
{prebuilt_}_platform_compat_config are collated by
`global_compat_config` via a singleton. The collated data is then used
in some CTS tests. At ToT, we ensure that the collation ignores the
platform_compat_config of prebuilt when source is selected, and vice
versa.
With trunk stable, multiple versions of prebuilt apexes and prebuilt
platform compat configs might exist in the tree. This CL uses
`Source_module_name` to hide the platform compat configs of the
unselected prebuilt apexes.
Bug: 322175508
Test: Added a unit test
Change-Id: Iafdde8fc0458b37b3ccde25433070936f144915c
WITHOUT_CHECK_API environment variable enables the checkapi to be
removed from the critical path. The variable is rarely used within AOSP,
but the downstream vendors may depend on it, in order to improve the
build performance given that the api signature file through metalava is
a resource costly task.
Currently, the exportable api files / removed api files are not
generated when checkapi is disabled, but a module may depend on the
exportable api files when a checkapi is disabled. In order to prevent
the missing build rules error in this case, generate the rule to copy
the checked in api file / removed api file to the exportable api file /
removed api file to prevent build errors.
This change also fixes the error message when the OutputFiles(string)
api file is null, to correctly inform the user the error.
Test: m BUILD_FROM_SOURCE_STUB=true WITHOUT_CHECK_API=true && inspect ninja path and verify that "non-updatable-exportable-current.txt" depends on the generated exportable api file.
Bug: 329374072
Change-Id: I24f88d450fb46b6ea9d5920d83617d8228edd34b