Commit Graph

3074 Commits

Author SHA1 Message Date
Jeongik Cha
ec87b5c85a Merge "Introduce AlwaysUsePrebuiltSdks" am: 6df337255c am: 497158434d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1356666

Change-Id: I92deaf13c3c7c7ae684bd11d5bd5d575d264bfb1
2020-08-10 01:25:06 +00:00
Jeongik Cha
6df337255c Merge "Introduce AlwaysUsePrebuiltSdks" 2020-08-10 00:51:56 +00:00
Treehugger Robot
b04255fc23 Merge "Merge libs/ directory of imported aars into classes.jar" am: 7189f5d1e2 am: 9a203fcd90
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1392878

Change-Id: I235cf9ed8a4926179b5b743570b08189609c6440
2020-08-08 01:20:59 +00:00
Treehugger Robot
7189f5d1e2 Merge "Merge libs/ directory of imported aars into classes.jar" 2020-08-08 00:51:38 +00:00
Colin Cross
205e91183e Merge libs/ directory of imported aars into classes.jar
AARs can provide extra classes in the libs/ directory that should
be treated the same as classes.jar, merge them into a single jar
when extracting the AAR.

Bug: 162892721
Test: m androidx.appsearch_appsearch
Change-Id: I92bf46f47ce5f3dce16c42197c15ed256304fda2
2020-08-07 14:07:23 -07:00
Jeongik Cha
816a23a50d Introduce AlwaysUsePrebuiltSdks
Instead of UnbundledBuild, use AlwaysUsePrebuiltSdks
to determine if java modules needs to be built against prebuilt sdks.
And rename UnbundledBuildUsePrebuiltSdks to AlwaysUsePrebuiltSdks to
express its behavior more correctly.(It can be orthgonal to "Unbundled")

Bug: 160390776
Test: TARGET_BUILD_UNBUNDLED_IMAGE=true m vendorimage

Change-Id: I0be7265c1959d8774c295372cd7a9250169f6df9
2020-08-07 12:15:52 +09:00
Ulyana Trafimovich
67ee1adb6a Merge "Add structured representation for colon-separated jar lists." am: 910eb70891 am: 434e708101
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1354005

Change-Id: I155b303e73442fb44f38621bf0fa9f2157a77370
2020-08-06 16:05:43 +00:00
Ulyana Trafimovich
910eb70891 Merge "Add structured representation for colon-separated jar lists." 2020-08-06 15:07:27 +00:00
Colin Cross
7f034dabf1 Merge "Add libraryDependencyTag to track dependencies on static and shared libraries" am: 2eddd06879 am: f6c453a3fd
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1378332

Change-Id: I20996cc0ed388013f24966a2d8a9462177bfe45e
2020-08-06 13:12:06 +00:00
Liz Kammer
c51a310131 Merge "Add property api_levels_jar_filename to droidstubs" am: 9c55b0efa2 am: a4278eba24
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1388544

Change-Id: Ic593590f8f3be3c66bcaa4d0a837dbe9fe865152
2020-08-06 13:11:11 +00:00
Liz Kammer
898ed67ecd Merge "Refactor java compileDex" am: 9eb51fc9d4 am: 46971c5469
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1360617

Change-Id: I574bbe46916d6e268956732f37022ba5f464fcaa
2020-08-06 13:10:52 +00:00
Colin Cross
2eddd06879 Merge "Add libraryDependencyTag to track dependencies on static and shared libraries" 2020-08-06 00:06:28 +00:00
Liz Kammer
9c55b0efa2 Merge "Add property api_levels_jar_filename to droidstubs" 2020-08-05 19:05:13 +00:00
Andrei Onea
9bdaf74c97 Rename hiddenapi manual lists
Use new names for lists from go/hiddenapi-list-renaming
Bug: 162827370
Test: m

Change-Id: I9522f32faa46d1d49aefad0921ba6d9c427d8779
2020-08-05 18:43:25 +01:00
Liz Kammer
9eb51fc9d4 Merge "Refactor java compileDex" 2020-08-05 15:41:03 +00:00
Ulya Trafimovich
249386ad69 Add structured representation for colon-separated jar lists.
With the addition of apexes and /system_ext some of the bootclasspath
and system server jars have moved from /system to the new locations.
This has been implemented by using lists of colon-separated strings
called "apex-jar pairs" (although "apex" was misleading as it could
refer to "platform" or "system_ext", not necessarily a real apex).

Using the colon-separated string representation is inconvenient, as it
requires splitting and reassembling the list components many times,
which harms performance and makes error handling difficult. Therefore
this patch refactors the colon-separated lists into a struct that
hides the implementation details.

Test: lunch aosp_cf_x86_phone-userdebug && m
Change-Id: Id248ce639a267076294f4d4d73971da2f2f77208
2020-08-05 09:59:30 +01:00
Liz Kammer
a7a64f3c5b Refactor java compileDex
We want to support a compile_dex property for java_import. This splits
dex-related properties into a dexer struct which can be embedded in
relevant modules.

Test: m
Test: soong tests
Bug: 160455085
Change-Id: If56a51dac43f630d49483a36db29cd50e9ccd529
2020-08-04 10:15:04 -07:00
Liz Kammer
3d894b728a Add property api_levels_jar_filename to droidstubs
The default is android.jar to maintain current behavior but allows users
to specify a different filepath to support generating api-versions for
docs other than the platform (e.g. auto).

Bug: 162552181
Test: m doc
Test: go test java_test
Change-Id: I9e51abaf7d5451d68ca782157d9b739f76c5da82
2020-08-04 09:55:13 -07:00
Andrei Onea
ca79081bde Rename hiddenapi manual lists
Use new names for lists from go/hiddenapi-list-renaming
Bug: 162827370
Test: m

Change-Id: I9522f32faa46d1d49aefad0921ba6d9c427d8779
2020-08-04 15:34:35 +01:00
Treehugger Robot
c03dc74149 Merge "Update language to comply with inclusive guidance" am: cf04073b43 am: abeb7c4538
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374706

Change-Id: Ie032c705309843d27f26699818fa6a8065808a99
2020-07-31 23:35:03 +00:00
Treehugger Robot
cf04073b43 Merge "Update language to comply with inclusive guidance" 2020-07-31 22:50:49 +00:00
Treehugger Robot
96ed484994 Merge "Default to not creating stubs for droiddoc" am: 703ea006e0 am: efb9bb4034
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1380730

Change-Id: Ibaca8954db797d938b6dff10c18014b9f2a97980
2020-07-31 19:46:04 +00:00
Treehugger Robot
703ea006e0 Merge "Default to not creating stubs for droiddoc" 2020-07-31 19:32:11 +00:00
Paul Duffin
0f460aa9db Fix prebuilt mutator ordering in tests am: 021f4e525f am: 8537c9cb30
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1380179

Change-Id: I77be0b785a95bdb943c8ead613f8e2d7b1d32776
2020-07-31 17:45:54 +00:00
Liz Kammer
1e2ee12ff4 Default to not creating stubs for droiddoc
This will allow us to remove `create_stubs: false` throughout the
codebase easily, then remove the functionslity to create stubs from
droiddoc.

Test: m docs
Test: m checkapi
Test: m updateapi
Bug: 144248501
Bug: 143136634

Change-Id: Ib95f68bc064fbe1475e4b25433bee6292bc005dc
2020-07-31 10:11:25 -07:00
Paul Duffin
021f4e525f Fix prebuilt mutator ordering in tests
Previously, the prebuilt mutators were added by the
cc.RegisterRequiredBuildComponentsForTest() function as a convenience
but unfortunately it lead to some of the mutators being in a different
order in the tests than in the normal build.

This change:
* Extracts the RegisterPrebuiltMutators() call from
  cc.RegisterRequiredBuildComponentsForTest()
* Makes sure that the prebuilt mutators are registered before the
  visibility gatherer and enforcer mutators.

Bug: 162505935
Test: m nothing
Change-Id: I7d959b558200b502f0a5e4653c41ea01414e142a
2020-07-31 16:12:01 +01:00
Andrei-Valentin Onea
48ca1e86e9 Merge "Update language to comply with Android's inclusive language guidance" am: 01124262f0 am: 06bd410548
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374496

Change-Id: Ia00d11ee4c75298b67e254e8a51924e5e154e4d5
2020-07-30 12:42:53 +00:00
Andrei-Valentin Onea
01124262f0 Merge "Update language to comply with Android's inclusive language guidance" 2020-07-30 12:09:00 +00:00
Colin Cross
6e511a9a9f Add libraryDependencyTag to track dependencies on static and shared libraries
dependencyTag uses a set of predefined tags to identify different types
of dependencies.  There are already multiple bits of metadata stored
in the dependency tag (Library, Shared, ReexportFlags), and supporting
them all requires a combinatorial explosion of predefined tags and
causes issues when using equality comparisons if a new bit of metadata
is added.

Add a new libraryDependencyTag type that will contain the metadata
bits, and replace the quality comparisons with checks on the metadata
bits.

There are 5 TODOs where modifying the checks identified problems with
the existing checks.  These were left in place to produce identical
build output and will be fixed separately.

Bug: 162437057
Test: no change to build.ninja or {Android,make_vars,late}-${TARGET_PRODUCT}.mk
Change-Id: I72d4207dcf381c07c92e00e5a03968ebb5ed8d30
2020-07-29 13:22:30 -07:00
Aleksei Kalinov
f0f5cdc1cc Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for
reference.

Bug: 161896447
Test: ran `m`.
Change-Id: If5ec29482911c281bc1c4bf2cfc84b2f05c2240d
2020-07-29 15:49:05 +00:00
Treehugger Robot
ad9cc7a602 Merge "Update language to comply with inclusive guidance" am: 0ebab772f5 am: 4b60484e5e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374704

Change-Id: Iaad293fce923748a6fba122f2ad234986ff73d9a
2020-07-29 04:14:13 +00:00
Treehugger Robot
0ebab772f5 Merge "Update language to comply with inclusive guidance" 2020-07-29 03:41:51 +00:00
Treehugger Robot
375337b0c8 Merge "Inclusive fix: Replace sanity to validation in java/sdk.go" am: 3d8e506c3a am: ffdfccd54c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374701

Change-Id: Iabe7ddfd5308a39ac1988a595faf02dde0e9370c
2020-07-29 00:11:05 +00:00
Treehugger Robot
3d8e506c3a Merge "Inclusive fix: Replace sanity to validation in java/sdk.go" 2020-07-28 23:39:20 +00:00
Liz Kammer
cada807a92 Update language to comply with inclusive guidance
Update android_app_set to use word install rather than master for
android_app_sets, this better matches the phrasing used for apex_set.

See https://source.android.com/setup/contribute/respectful-code for
reference

Bug: 161896447
Test: m nothing
Change-Id: I429e7f8b16c42c10ad4d9543110f5ce814a893b1
2020-07-28 15:47:38 -07:00
Treehugger Robot
c27bb4650c Merge "Update language to comply with inclusive guidance" am: 9326ba770c am: ebdbfbf539
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374702

Change-Id: Ib9d0835e842474dbf244eebd08cc0c774170db98
2020-07-28 21:50:28 +00:00
Liz Kammer
7941b30c67 Update language to comply with inclusive guidance
See https://source.android.com/setup/contribute/respectful-code for
reference

Bug: 161896447
Test: m nothing
Change-Id: I13f42b680c6b819a2708c973e7718267c121f862
2020-07-28 13:27:34 -07:00
Liz Kammer
20ebfb46fc Update language to comply with inclusive guidance
See https://source.android.com/setup/contribute/respectful-code for
reference

Bug: 161896447
Test: m nothing
Change-Id: Ie1d0d63d27f1b1b48680922b7202aa6df04f4696
2020-07-28 11:37:31 -07:00
Patrice Arruda
b481b87104 Inclusive fix: Replace sanity to validation in java/sdk.go
Bug: b/161896447
Test: "lunch 1" and "m nothing"
Change-Id: I8cbdec02dccd961a8cac92c6e957aeebd1e263c1
2020-07-28 18:30:44 +00:00
Liz Kammer
82fdacaf3c Merge "Add data_native_bins property to java_test_host" am: 8ffde8c9d5 am: 30de260bee
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1358802

Change-Id: I090dafbabe34c88dcd394960798499129746294f
2020-07-28 16:42:04 +00:00
Liz Kammer
dd849a81f3 Add data_native_bins property to java_test_host
When multiple os/arch variants are supported, java_test_host could not
find a matching arch due to java having arch:common, whereas native
binaries support a specific architecture. This change adds the property
`data_native_bins` in order to support binaries with the appropriate
os/arch variants.

Test: m FirmwareDtboVerification with data_native_bins
Test: forrest
Bug: 153848038
Change-Id: I45adebff0fde2811d5ef5620c697b97b768c951f
2020-07-27 09:14:06 -07:00
Treehugger Robot
4826c2668d Merge "Build transitive lint reports for apex modules" am: 13aa44fc15 am: 5388d97b37
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1370779

Change-Id: I08069e90ec451f09aa7bbea3e8b4834d6cb7ef67
2020-07-24 12:16:40 +00:00
Treehugger Robot
13aa44fc15 Merge "Build transitive lint reports for apex modules" 2020-07-24 11:50:39 +00:00
Dan Stoza
d550a9a6e6 Merge "Add SettingsRoboTests to the allow-list for legacy core/platform API." into stage-aosp-master am: e05c751f38
Original change: https://googleplex-android-review.googlesource.com/c/platform/build/soong/+/12220305

Change-Id: Ie520daea74b7847e8e307d1f2c5b4e356935e8f2
2020-07-23 22:40:06 +00:00
Pete Gillin
d5c16eb731 Add SettingsRoboTests to the allow-list for legacy core/platform API.
Bug: 161967461
Test: m SettingsRoboTests
Change-Id: If4e58fba5f74dd06457497c1d131bc1f273f6f5b
2020-07-23 20:47:11 +00:00
Pete Gillin
9f4893d86f Add SettingsRoboTests to the allow-list for legacy core/platform API.
Bug: 161967461
Test: m SettingsRoboTests
Merged-In: I15e5a6c2f07e73718803501d705de0d7ab9bec90
Change-Id: If4e58fba5f74dd06457497c1d131bc1f273f6f5b
2020-07-23 12:34:07 +01:00
Pete Gillin
84c3807b99 Enforce the legacy core/platform API restriction.
This change silently decides whether modules which depend on either
sdkPrivate or sdkCorePlatform get the legacy or the stable version of
the core/platform API, based on whether the module's name is on a
hard-coded list or not.

Test: m java
Test: make a target from the list when its entry is commented out, which correctly fails
Bug: 157640067
Change-Id: I15e5a6c2f07e73718803501d705de0d7ab9bec90
Merged-In: I15e5a6c2f07e73718803501d705de0d7ab9bec90
Merged-In: Iaa97ddaa015e8079fcb3426585c5101c7ec9e22a
(cherry picked from commit c0f4373106)
2020-07-23 09:06:52 +01:00
Colin Cross
08dca38eb0 Build transitive lint reports for apex modules
Build and export transitive lint report zips for apex modules.

Bug: 153485543
Test: m TARGET_BUILD_APPS=com.google.android.wifi lint-check dist
Change-Id: I5a1805440452301a7e2c4ca91482b989638b54fb
2020-07-22 20:16:14 -07:00
Pete Gillin
e64cf6e0ff Placeholder for enforcement of the legacy core/platform API restriction.
This does is as similar as possible to the equivalent changes in AOSP
and internal masters, without actually doing any enforcement. This
means we don't have to maintain a third hard-coded list for rvc, while
minimizing the diffs. The list here is identical to the one in AOSP
master, so changes from there should merge down cleanly (and have no
effect).

Test: m java checkapi
Bug: 157640067
Change-Id: Iaa97ddaa015e8079fcb3426585c5101c7ec9e22a
Merged-In: I15e5a6c2f07e73718803501d705de0d7ab9bec90
(cherry picked from commit c0f4373106)
2020-07-22 17:42:24 +01:00
Treehugger Robot
00317f0660 Merge "Generate module lib API and scope together" am: 0bcda81dd5 am: 6e6dd4be10
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1367357

Change-Id: I047e414976c4eae6bfec37aa1c18bed2f6cb4063
2020-07-21 04:45:26 +00:00