summaryrefslogtreecommitdiff
path: root/java
AgeCommit message (Collapse)Author
2021-10-18Merge changes Ifa4594ea,Ia756f309 Colin Cross
* changes: Reduce commands per shard for java protos Up per-product memory usage to 30 GB
2021-10-18Reduce commands per shard for java protos Colin Cross
`m platformprotos` with a long OUT_DIR can trigger E2BIG errors in posixspawn, reduce the commands per shard. Test: OUT_DIR=$PWD/really-long-out-directory m platformprotos Change-Id: Ifa4594eac7ba0e1091df0ef75e4dfc3ff366939b
2021-10-15Merge "Extract the logic of setting Uncompress_dex to a common place." Jiakai Zhang
2021-10-13Add android_sdk_repo_host to build platform-tools&build-tools Dan Willemsen
The Android SDK has been built with Make up until now, monolithically, then split up into several sdk-repo zip files for different purposes. The Mac and Windows SDKs really only need to contain the platform-tools and build-tools pieces, but due to this monolithic sdk zip, we had to build the whole SDK first. This adds an `android_sdk_repo_host` module that can build these platform-tools and build-tools zips. Bug: 187222815 Change-Id: I55809e1d7447dd65e22461f921b2b8abb6d5f822
2021-10-11Merge "Allow defaults in java_genrule modules" Steven Moreland
2021-10-11Merge "Update reference to merged services txt" Anton Hansson
2021-10-11Extract the logic of setting Uncompress_dex to a common place. Jiakai Zhang
Bug: 194150908 Test: m nothing Change-Id: Ia33965067586cfd48183e6d17f5d17626eef3c5a
2021-10-08Allow defaults in java_genrule modules Colin Cross
Call InitDefaultableModule in java_genrule factories to allow the defaults property to be used. Bug: 202547639 Test: m checkbuild Change-Id: I3a5960304af3e9babb30d036d63016087000d773
2021-10-08Update reference to merged services txt Anton Hansson
The module is changing name. Update the reference. Bug: 169103987 Test: m Change-Id: I1e3f05b6d9c0262adcde6881ea79df9338bb363a
2021-10-07Merge "Merge Android 12" Xin Li
2021-10-07Merge "Add module-lib to droidstubs' supported sdk types" Pedro Loureiro
2021-10-06Merge "Allow implementation details to be excluded from signature patterns ↵ Paul Duffin
file" am: 6546573ec9 Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1788094 Change-Id: I28f0ddcfe3746a8bf37471f9f1c9b9771fab690a
2021-10-05Retry: Separate hidden API flags needed in sdk snapshots for S and T am: ↵ Paul Duffin
191be3a186 Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844294 Change-Id: Id8977b8160f175b736214428cae94ea27f95675b
2021-10-05Add module-lib to droidstubs' supported sdk types Pedro Loureiro
If the android.jar is not found in the module-lib folder, it falls back to searching it in the system folder and then falls back on the public folder. This only brings the functionality, we are not yet using it. Test: m nothing Bug: 202023154 Change-Id: I99c9004740c8e51faf53ebc3ba2444e8164215f3
2021-10-05Allow implementation details to be excluded from signature patterns file Paul Duffin
Previously, the signature-patterns.csv file (which was output in an sdk snapshot) included implementation details, e.g. the names of classes that are not part of any API, including the hidden API. This change allows a bootclasspath_fragment module owner to customize the generated signature patterns file to remove as many implementation details as possible from the sdk snapshot. That means that implementation only changes would not require that sdk snapshots be updated in sync with the corresponding APEX. Module owners can remove implementation in the following ways: 1) Limit the number of packages that are treated as split packages by explicitly specifying the split packages in the split_packages property. A split package is one whose classes are provided by separate bootclasspath_fragment modules and so the signature patterns has to include every class in that package provided by a specific bootclasspath_fragment module, including implementation classes, instead of just listing the package. The default is to treat all packages as being split, so if no split_packages is specified then it defaults to ["*"] which matches all packages. Assuming that no package was split unless specifically stated would require that all the modules that had split packages explicitly list them before this change could be submitted as without them this change would break the build. Once all existing modules with split packages have been updated to include them then the default may be changed. 2) Adding package prefixes for any hierarchy of packages that are owned solely by that bootclasspath_fragment. This removes the need to list the packages in that hierarchy, including implementation specific packages. Bug: 194063708 Test: atest --host verify_overlaps_test signature_patterns_test m out/soong/hiddenapi/hiddenapi-flags.csv - manually change files to cause difference in flags to check that it detects the differences. Change-Id: If2f90cfc41b6fff9fa4ac8b9d4973110938b9392
2021-10-05Retry: Separate hidden API flags needed in sdk snapshots for S and T Paul Duffin
Previous change that was reverted: https://r.android.com/1835222 An additional test was added that revealed a bug in the previous change which has been fixed here. Previously, the behavior of the stub_flags and all_flags properties was different between S and T. In S they contained paths for the complete set of stub flags and all the encoded flags. However, in T they contained filtered sets of flags which if used in S would prevent build checks from detecting possible inconsistencies. Also, a new signature_patterns property was added in T that is not supported in S. This change creates separate properties/files for T and reverts the behavior of the properties/files that were added in S back to how they behaved in S. The new properties are called filtered_stub_flags and filtered_flags. The S and T properties are tagged with the appropriate supported_build_releases tag to ensure that they are only output when specifically targeted. Bug: 197842263 Test: m nothing Change-Id: I1ce0a3d6623dabf73e32af1a7457b9b444fc3b7c
2021-10-04Merge "Bp2Build common properties auto-handling" am: d905146590 Treehugger Robot
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1815376 Change-Id: I38f1063302ea90583a51e625076e6232b4364ab7
2021-10-04Merge "Bp2Build common properties auto-handling" Treehugger Robot
2021-10-04Update variable name in error messages. am: e5b2b49a73 Ulya Trafimovich
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844308 Change-Id: Icb57f58d9efdf8793162254eefe8e3150d6d9cf5
2021-10-04Update variable name in error messages. Ulya Trafimovich
Variable PRODUCT_UPDATABLE_SYSTEM_SERVER_JARS was renamed to PRODUCT_APEX_SYSTEM_SERVER_JARS in https://r.android.com/1779472. Bug: 191127295 Test: m nothing Change-Id: I0c8ae839cab443c824760b40d30b4374982010f9
2021-10-04Bp2Build common properties auto-handling Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
Introduce `commonAttributes` & `fillCommonBp2BuildModuleAttrs used in CreateBazelTargetModule Adapt `bp2BuildInfo` to use `commonAttrs` instead of `Name`. And thus also all downstream users of `CreateBazelTargetModule`. As initial user, the Soong `required` property will be translated to Bazel's `data`. Bug: 198146582, 196091467 Test: build_converstion_test.go:TestCommonBp2BuildModuleAttrs Test: go test Test: mixed_{libc,droid}.sh Change-Id: Ib500e40f7e2cb48c459f1ebe3188962fc41ec124
2021-10-04Remove unnecessary additionalCheckedModules field am: 0b58fdb058 Paul Duffin
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842815 Change-Id: Ic6e55395138cfed7257529b2c5165bb4907460e1
2021-10-04Remove unnecessary additionalCheckedModules field Paul Duffin
This change removes the field and the code that uses it which is effectively dead code as it only does something when the list is not empty and a previous change removed the only code that added a Path to this list. Bug: 201753898 Test: m nothing Change-Id: I67c74ad2a3b115fd3b20b3b416f45b92c749749c
2021-10-04Merge changes from topic "bb_201948713" am: 8bb9c6a1d9 Salmax Chang
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844137 Change-Id: Ia042b5b24141be4ebfa17ab15adf34c3af632635
2021-10-04Merge changes from topic "bb_201948713" Salmax Chang
* changes: Revert "Support generating sdk snapshot for specific build release" Revert "Separate hidden API flags needed in sdk snapshots for S and T"
2021-10-04Revert "Separate hidden API flags needed in sdk snapshots for S and T" Salmax Chang
This reverts commit ba68c936305eeec354ad62192173a147eb3e6348. Reason for revert: suspect to cause build break in b/201948713 Change-Id: Ide3693ac1f8e24bd2f7c12857361885cb6b787ef
2021-10-02Merge "Separate hidden API flags needed in sdk snapshots for S and T" am: ↵ Paul Duffin
6b383e9ef2 Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1835222 Change-Id: I092500dc977cc482a6c662ae9fcd4e71fea32810
2021-10-02Merge "Always perform permitted package check when building a library" am: ↵ Paul Duffin
f7db6ebaa1 Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842459 Change-Id: I8be5f7deb33b67b5307cb3a4551f659414a3aee9
2021-10-02Merge "Separate hidden API flags needed in sdk snapshots for S and T" Paul Duffin
2021-10-02Merge "Always perform permitted package check when building a library" Paul Duffin
2021-10-02Merge "Preopt APEX system server jars for java_import." am: 6f0c1a1e0c Treehugger Robot
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1840056 Change-Id: Ifc6895e47d0e7e6ed7d593a9d5d767f6cd2cf566
2021-10-02Merge "Preopt APEX system server jars for java_import." Treehugger Robot
2021-10-01Merge changes from topics "bp-bionic-cts-tests", ↵ Colin Cross
"cts-per-testcase-directory" am: 2df9ebf9ca Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1838375 Change-Id: I9fd93be8154f2f1372ccde1eb9a37690738692b7
2021-10-01Separate hidden API flags needed in sdk snapshots for S and T Paul Duffin
Previously, the behavior of the stub_flags and all_flags properties was different between S and T. In S they contained paths for the complete set of stub flags and all the encoded flags. However, in T they contained filtered sets of flags which if used in S would prevent build checks from detecting possible inconsistencies. Also, a new signature_patterns property was added in T that is not supported in S. This change creates separate properties/files for T and reverts the behavior of the properties/files that were added in S back to how they behaved in S. The new properties are called filtered_stub_flags and filtered_flags. The S and T properties are tagged with the appropriate supported_build_releases tag to ensure that they are only output when specifically targeted. Bug: 197842263 Test: m nothing Change-Id: Iec8b9c539796c507245b69c0aed980fde6d8694f
2021-10-01Merge changes from topics "bp-bionic-cts-tests", "cts-per-testcase-directory" Colin Cross
* changes: Add data_bins property Support per-testcase directories in all test suites Add environment variables to cc_genrule commands
2021-10-01Always perform permitted package check when building a library Paul Duffin
Previously, the permitted package check was designed to only be run when building checkbuild. Although, that appears to now be broken. This change uses a Validation dependency to ensure that the package check is performed whenever the output file of a java_library is built as part of the build. The package check runs in parallel with any other rules that depend on the file. Bug: 201753898 Test: - change the permitted_packages property in frameworks/base/test-mock so that the package check will fail. m out/soong/.intermediates/frameworks/base/test-mock/android.test.mock/android_common/package-check.stamp - as expected the package check failed. m droid - as expected the package check did not fail. # Made these changes then: m droid - as expected the package check now failed. Change-Id: Id38fe280c79e5505ee4555b845c6da2ae6747bc4
2021-09-30Merge changes I7876b077,Ib2e7d5e6,I7d2d2e02,Ibf5322f8 am: dcc42b6f7e Jiakai Zhang
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1835088 Change-Id: Ifefcf876e203406967f44c035495dbba49c4362f
2021-09-30Preopt APEX system server jars for java_import. Jiakai Zhang
Similar to aosp/1821985, but for java_import. Bug: 194150908 Test: See the next CL. Change-Id: Ied1cfb1a7e1c2eea502b74b0d6e2344bcd02155e
2021-09-30Generate prebuilt_systemserverclasspath_fragment. Jiakai Zhang
Bug: 194150908 Test: m nothing Test: manual - 1. Patch aosp/1835087. 2. m out/soong/.intermediates/art/build/sdk/art-module-sdk/common_os/snapshot/Android.bp 3. See prebuilt_systemserverclasspath_fragment modules and systemserverclasspath_fragments in an sdk_snapshot module. Change-Id: I7876b077b0b4ed190f01dbfa9533de04ea32d524
2021-09-30Add a new SDK member type java_systemserver_libs. Jiakai Zhang
Similar to java_boot_libs, java_systemserver_libs only provide access to their dex implementation jar for use by dexpreopting and do not provide an actual implementation jar. This is used in the subsequent CL. Bug: 194150908 Test: m nothing Change-Id: Ib2e7d5e6c002314a0231f46934a766f4a27e610a
2021-09-30Add exported_systemserverclasspath_fragments to prebuilt_apex rule. Jiakai Zhang
This is for exporting the contents of systemserverclasspath_fragment for dexpreopting. Bug: 194150908 Test: manual - 1. Patch aosp/1818020 and aosp/1834534 2. m SOONG_CONFIG_art_module_source_build=false com.android.art Change-Id: I7d2d2e02869d8a523f7c0efbbff81706672a95c5
2021-09-30Add prebuilt_systemserverclasspath_fragment rule. Jiakai Zhang
This is the prebuilt side of systemserverclasspath_fragment, currently for used for dexpreopting. The change to automactially generate prebuilt_systemserverclasspath_fragment rules will be in a separate CL. Bug: 194150908 Test: m nothing Change-Id: Ibf5322f80f78ac3ca037489f4a279456fe38a23f
2021-09-27Support per-testcase directories in all test suites Colin Cross
There are cases where two modules try to install the same test data into CTS, which results in collisions when CTS puts the data for all tests in the same directory. Add a flag that allows enabling a per-testcase directory for an individual test for all test suites. Bug: 193168159 Test: cts-tradefed run commandAndExit CtsBionicTestCases Change-Id: If034723e8fe937ca71d3e2d39b7d46702e41bc8c
2021-09-26Merge "Remove updatable-bcp-packages.txt." am: a14b18fb31 Jiakai Zhang
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1832483 Change-Id: If17f9cb0d0cef77ea2d2fc3f0ddac177f449daca
2021-09-26Merge "Remove updatable-bcp-packages.txt." Jiakai Zhang
2021-09-24Merge "Add phony name for robolectric tests" am: ffe2c918e9 Colin Cross
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1831866 Change-Id: I94f283455b3ddecad3d932d7bdbdab902ff211ee
2021-09-24Merge "Add phony name for robolectric tests" Colin Cross
2021-09-24Add phony name for robolectric tests Colin Cross
Robolectric tests are installed by Soong, which means Make doesn't know about the install location to create the phony rules. Add a phony rule in Soong for now until Soong's installation rules are fleshed out. Bug: 184946827 Test: m SettingsRoboTests Change-Id: I60d76474949800e1a737714d86df84eff9a92214
2021-09-24Merge changes I957f3df8,I68986dcc am: cf6bf37d04 Martin Stjernholm
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1829372 Change-Id: Ifcf471f2746c1037b83c2a11b8f5120b86fd6cb2
2021-09-24Merge changes I957f3df8,I68986dcc Martin Stjernholm
* changes: Consolidate the code to resolve a deapexer module dependency. Propagate the dex jar path as an OptionalPath which is either valid or invalid with a message.