Commit Graph

3635 Commits

Author SHA1 Message Date
Anton Hansson
880cb13323 Merge "Add a better error message for missing api files" am: 4de3c42c73 am: 54431da641 am: 842d34ac7b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555156

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4072a0dc145efbc3e1968cadd32656b8d2efccf1
2021-01-22 12:06:29 +00:00
Anton Hansson
842d34ac7b Merge "Add a better error message for missing api files" am: 4de3c42c73 am: 54431da641
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555156

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1bfaf36ad15e2c771872fd80dc31d750cdeeffe0
2021-01-22 11:52:47 +00:00
Anton Hansson
4de3c42c73 Merge "Add a better error message for missing api files" 2021-01-22 10:31:15 +00:00
Nicolas Geoffray
981c30ca1e Merge "dexpreopt: Use the dirty-image-objects path from frameworks/base." am: 324234bd00 am: d2aff3c2a1 am: e707c51e31
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555155

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ica0522d7c8cad6c00fe444178d11fa3a5e1833c7
2021-01-20 19:47:31 +00:00
Ulyana Trafimovich
1a2949251b Merge "Support building boot images with disabled dexpreopt." am: 0caabb6e27 am: 5602cf202b am: fb9314da42
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555134

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5c35fc8382ab51307e4cb5e4a0b8b2d4c5553f8b
2021-01-20 19:46:47 +00:00
Bill Peckham
dccab29858 Merge changes from topic "prebuilt-hiddenapi" am: 1c8e5e817e am: 24ac16d6e6 am: 96ddf7f0b3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1546365

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I626d7b1481b000c75a949522b91db36fc2fe213a
2021-01-20 19:46:31 +00:00
Anton Hansson
e77fccc959 Add a better error message for missing api files
Add some instructions for what to do.

Bug: 177806245
Test: m nothing (with java_sdk_library with no tracking files)
Change-Id: I286018f4d9105d5ade1e76cddb8670d0d097d77d
2021-01-20 19:21:16 +00:00
Nicolas Geoffray
e707c51e31 Merge "dexpreopt: Use the dirty-image-objects path from frameworks/base." am: 324234bd00 am: d2aff3c2a1
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555155

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4e92e1ae8713f5451c9aa8aa097a576c3cd0f1a2
2021-01-20 19:02:51 +00:00
Ulyana Trafimovich
fb9314da42 Merge "Support building boot images with disabled dexpreopt." am: 0caabb6e27 am: 5602cf202b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555134

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I21223b7babf61153570127b16157217316dfe52c
2021-01-20 19:02:18 +00:00
Bill Peckham
96ddf7f0b3 Merge changes from topic "prebuilt-hiddenapi" am: 1c8e5e817e am: 24ac16d6e6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1546365

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1e9ae289f82169794342723ba653a95a1f79241a
2021-01-20 19:02:05 +00:00
Nicolas Geoffray
324234bd00 Merge "dexpreopt: Use the dirty-image-objects path from frameworks/base." 2021-01-20 18:13:20 +00:00
Ulyana Trafimovich
0caabb6e27 Merge "Support building boot images with disabled dexpreopt." 2021-01-20 17:46:02 +00:00
Bill Peckham
1c8e5e817e Merge changes from topic "prebuilt-hiddenapi"
* changes:
  Supply LOCAL_SOONG_DEX_JAR for java_import with compile_dex.
  Enable an apex to include a java_import.
  Enable prebuilt hiddenapi CSV files.
2021-01-20 17:43:48 +00:00
Nicolas Geoffray
1086e604b9 dexpreopt: Use the dirty-image-objects path from frameworks/base.
Test: m
Bug: 176171716
Change-Id: Ifbc08ae03e2b1bec7161948970bd197386e3b305
2021-01-20 14:31:32 +00:00
Ulya Trafimovich
a4a1c4ee98 Support building boot images with disabled dexpreopt.
Bug: 176171716
Test: build_mainline_modules.sh and ensure that the ART boot image is
    built: `find out -type f -name '*.art'` is nonempty for every arch.
Change-Id: Ibc45581eef2b205c750a30709780cf659ba7cfa1
2021-01-20 14:03:07 +00:00
JaeMan Park
518e0d3ac2 Merge "Make TestJavaSdkLibraryEnforce faster" am: cdbbb1ea68 am: 4198b5c05a am: 6f4465cd8d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549896

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id839aafd0d44904eba24b66c5f9c784546f1fa96
2021-01-20 02:15:36 +00:00
JaeMan Park
6f4465cd8d Merge "Make TestJavaSdkLibraryEnforce faster" am: cdbbb1ea68 am: 4198b5c05a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549896

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iba0c06839f0d0ecce8c660f03fb9dc44a36b180a
2021-01-20 01:52:57 +00:00
JaeMan Park
cdbbb1ea68 Merge "Make TestJavaSdkLibraryEnforce faster" 2021-01-20 00:00:54 +00:00
Bill Peckham
fb04df4d57 Supply LOCAL_SOONG_DEX_JAR for java_import with compile_dex.
Without LOCAL_SOONG_DEX_JAR, ninja fails with a missing
dependency error.

Test: m nothing
Test: new TestImportSoongDexJar
Bug: 173705556
Change-Id: I54a4c6ea93877667a3fb97f8b2621c42e431f577
2021-01-19 18:15:16 +00:00
Bill Peckham
a41a6963b4 Enable an apex to include a java_import.
With the addition of the compile_dex property to the
java_import module it becomes possible to include a
java_import module in an apex. This change allows the
dependency and adds a test.

Bug: 177228901
Test: m nothing
Test: new TestApexWithJavaImport
Change-Id: I9336dade1857109e2fd21f7d57e1dc4abc4a402c
2021-01-19 18:15:03 +00:00
Bill Peckham
bae4749de2 Enable prebuilt hiddenapi CSV files.
By enabling these hiddenapi CSV files to be prebuilt, it
becomes possible to create a split build that supports
the hiddenapi encode dex step, but doesn't contain all
of the java sources needed to generate the CSV files.

Bug: 175048716
Test: m nothing
Test: new TestHiddenAPISingletonWithPrebuiltCsvFile
Test: local build without prebuilt hiddenapi
Test: local build with prebuilt hiddenapi
Change-Id: I805ea3ec05860d2df211a3985ec025bf36f0d775
2021-01-19 10:07:45 -08:00
Paul Duffin
d8733e056d Merge "Export dex implementation jars from prebuilt_apex" am: fe6147eb26 am: c022da2b2a am: bf4b8488e9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1523984

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1ec430725444022e43e9532964fdf4134031158c
2021-01-19 16:43:57 +00:00
Paul Duffin
bf4b8488e9 Merge "Export dex implementation jars from prebuilt_apex" am: fe6147eb26 am: c022da2b2a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1523984

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If1a7c988c1afe2d53982d33ffc2b93853189169c
2021-01-19 15:56:16 +00:00
Colin Cross
ff294f8d9c Merge "Revert "Add ArcSettings and SettingsGoogle to the legacy allowlist"" 2021-01-19 05:28:29 +00:00
Colin Cross
ce2b781448 Revert "Add ArcSettings and SettingsGoogle to the legacy allowlist"
Revert "Export proguard.flags, manifest and sources for use by S..."

Revert submission 13183140-SettingsGoogle-bp

Reason for revert: b/177766209
Reverted Changes:
I73bef76ec:Add ArcSettings and SettingsGoogle to the legacy a...
I385629c5c:Build Settings-robo-testutils for use by SettingsG...
I863e1d658:Convert ArcSettings to Android.bp
If095bc39d:Convert SettingsGoogleRoboTests to Android.bp
I8d3f32cd4:Convert SettingsGoogle tests to Android.bp
I7ddeb985c:Convert SettingsGoogle to Android.bp
I3b8223e64:Export elmyra and columbus aidl files for Settings...
I3d2f042a9:Export proguard.flags, manifest and sources for us...

Change-Id: I76e7d6ae91e838f03fce081d1b580e4e7b763c8b
2021-01-19 05:23:08 +00:00
Treehugger Robot
c60d8d0756 Merge "Add java_boot_libs to sdk" am: 2b72906ade am: 34309dcaa9 am: e40ff6cf08
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1526699

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic40ec096711eb48b884421f58a0a6be5f39e9dfd
2021-01-16 01:47:59 +00:00
Colin Cross
8d038bfccb Merge "Add ArcSettings and SettingsGoogle to the legacy allowlist" 2021-01-16 01:45:52 +00:00
Treehugger Robot
e40ff6cf08 Merge "Add java_boot_libs to sdk" am: 2b72906ade am: 34309dcaa9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1526699

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I361dd4062668a5731a98f088f53f687864ae2dd2
2021-01-16 01:20:10 +00:00
Paul Duffin
064b70c918 Export dex implementation jars from prebuilt_apex
Dexpreopt and boot jars package check all require access to dex
implementation jars created for java_library and java_sdk_library. They
were available when building from source but not when building from
prebuilts, even though they are embedded within the .apex files that
are referenced from prebuilt_apex.

This changes adds support to prebuilt_apex to export the dex
implementation jars and updates java_import to use those exported dex
implementation jars.

In a source build dexpreopt/boot jars package check access the apex (or
platform) specific variant of a java_library, e.g. core-oj, from which
it retrieves the dex implementation jar path.

After this change in a prebuilt build dexpreopt/boot jars package check
behave in the same way except in this case they retrieve the dex
implementation jar path from the apex (or platform) specific variant of
the java_import, e.g. core-oj.

The work to export files from a `.apex` file for use by other modules
is performed by a new `deapexer` module type. It is not used directly
in an `Android.bp` file but instead is created implicitly by
`prebuilt_apex`,

In order to do that this contains the following changes:
* Adds a new `dexapexer` module type to handle the exporting of files
  from the `.apex` file.
* Adds an exported_java_libs property to prebuilt_apex to specify the
  set of libraries whose dex implementation jars need exporting.
* Creates apex specific variants of the libraries listed in the
  exported_java_libs property.
* Adds the set of exported files to the ApexInfo to make them available
  to the apex specific variants.
* Prevents the prebuilt_apex variants from being merged together as
  they will not be compatible.
* Modifies java_import to use the exported file for variants of a
  prebuilt_apex.
* Adds a ninja rule to unpack (using deapexer) the contents of the
  prebuilt_apex's apex file, verify that the required files are present
  and make them available as outputs for other rules to use.
* Some minor refactorings to support these changes.
* Adds tests to cover prebuilt only, prebuilt with source preferred,
  and prebuilt preferred with source.

Test: m nothing
Bug: 171061220
Change-Id: Ic9bed81fb65b92f0d59f64c0bce168a9ed44cfac
2021-01-15 18:14:10 +00:00
Paul Duffin
db170e4a92 Add java_boot_libs to sdk
The build has some implicit dependencies (via the boot jars
configuration) on a number of modules, e.g. core-oj, apache-xml, that
are part of the java boot class path and which are provided by mainline
modules (e.g. art, conscrypt, runtime-i18n) but which are not otherwise
used outside those mainline modules.

As they are not needed outside the mainline modules adding them to
the sdk/module-exports as either java_libs, or java_header_libs would
end up exporting more information than was strictly necessary. This
change adds the java_boot_libs property to allow those modules to be
exported as part of the sdk/module_exports without exposing any
unnecessary information.

Some points to note:
* The java_import has to have a valid file for the src property
  otherwise it will be disabled.
* The src property is supposed to reference a jar file but the
  java_boot_libs property will make it reference an empty file (not
  an empty jar) so that any attempt to use that file as a jar, e.g.
  compiling against it, will cause a build failure.
* The name of the file passed to the src property should make it
  clear that the file is not intended to be used.
* The test makes sure that only the jar file is copied to the
  snapshot.

Test: m nothing
Bug: 171061220
Change-Id: I175331e4c8e3874ab70a67cdc2f76ed1576e41eb
2021-01-15 18:14:10 +00:00
JaeMan Park
90e75350d7 Make TestJavaSdkLibraryEnforce faster
TestJavaSdkLibraryEnforce is too slow because it tests all
combinations of options. Change TestJavaSdkLibraryEnforce to
run test on specific test cases, not all combinations.

Bug: 177323052
Test: go test -timeout 10s -run ^TestJavaSdkLibraryEnforce$ android/soong/java
Change-Id: Ie7fe4e22b570a3e25259a6ad4bd37936805c6604
2021-01-15 13:24:09 +09:00
Mathew Inwood
bc6b491be8 Merge "Move temp blocklist APIs to max-sdk-r list." am: ecbe5598fc am: 3144918c99 am: ff759493c3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549976

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id1b3a6ccbb71cf8e67f4e5bd534ccc7b020f6911
2021-01-14 12:15:35 +00:00
Mathew Inwood
ff759493c3 Merge "Move temp blocklist APIs to max-sdk-r list." am: ecbe5598fc am: 3144918c99
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549976

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia0e3eb2de02b5512762bb4439308ed368bd590dc
2021-01-14 11:33:55 +00:00
Mathew Inwood
c1be2f8105 Move temp blocklist APIs to max-sdk-r list.
These APIs were temporarily blocked but are now being moved to the
max-sdk-r for final release. Tag these APIs as "lo-prio" since we
believe that they are unused.

Bug: 173499988
Test: m
Change-Id: If9c6be963faa75df77cf3cc7761b384324c8cd3e
2021-01-13 15:49:17 +00:00
Colin Cross
91c750739c Add ArcSettings and SettingsGoogle to the legacy allowlist
Settings-core is already in the allowlist, ArcSettings and
SettingsGoogle need to compile the same source files but were
in Android.mk files.  Add them to the allowlist so they can
be converted to Android.bp.

Bug: 175124789
Test: m RunSettingsGoogleRoboTests RunArcSettingsRoboTests
Change-Id: I73bef76ecc517223827ac6f3cb1f0624c738fb9d
2021-01-13 00:12:28 +00:00
Colin Cross
e7a71fa844 Merge "Reduce legacy_core_platform_api_usage.go" 2021-01-13 00:10:34 +00:00
Colin Cross
5cf56302e5 Reduce legacy_core_platform_api_usage.go
Rerun the tools in ag/12184151 to remove unnecessary entries
from legacy_core_platform_api_usage.go.

Test: m checkbuild
Change-Id: I7467ce97fbd863371f5a732c34e647c660fca184
2021-01-11 18:11:47 -08:00
Ulyana Trafimovich
e66d78339b Merge "Remove obsolete class loader context API and update unit tests." am: 53230fefa3 am: 9f19d6b988 am: e2edc31bb9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1538885

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If8884f380bea51c59ad03cfe808c089e92303276
2021-01-08 17:55:11 +00:00
Ulyana Trafimovich
e2edc31bb9 Merge "Remove obsolete class loader context API and update unit tests." am: 53230fefa3 am: 9f19d6b988
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1538885

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8f0c9c8566829fb6a6788846919ff47d43f2c3b7
2021-01-08 17:38:41 +00:00
Ulyana Trafimovich
53230fefa3 Merge "Remove obsolete class loader context API and update unit tests." 2021-01-08 17:00:56 +00:00
Bob Badour
ed04b47876 Merge changes from topic "revert-1541855-revert-1377717-metalics-BOEMJWNSHV-PBOZXBJQZD" am: ddac9bf3f2 am: adf19116d3 am: 72deb7feda
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1540840

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I5799dc9b0af0a0f2f36413ed69341dc318cf96ed
2021-01-07 23:48:20 +00:00
Bob Badour
72deb7feda Merge changes from topic "revert-1541855-revert-1377717-metalics-BOEMJWNSHV-PBOZXBJQZD" am: ddac9bf3f2 am: adf19116d3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1540840

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I17c75654bf575e5ebdee04fdbb48932c151088c0
2021-01-07 23:21:14 +00:00
Bob Badour
ddac9bf3f2 Merge changes from topic "revert-1541855-revert-1377717-metalics-BOEMJWNSHV-PBOZXBJQZD"
* changes:
  Revert^2 "Define the standard license_kind rules."
  Revert^2 "Export soong license data to make."
  Revert^2 "Add ability to declare licenses in soong."
2021-01-07 22:42:08 +00:00
Bob Badour
b499922acc Revert^2 "Export soong license data to make."
61a55a0344

Change-Id: I5fb017c683df18bad42a8e27fb2d7c7c510514e5
2021-01-06 20:49:11 -08:00
Jooyung Han
a2861d19f5 Merge "Add "aidl.flags:" property for cc_/java_ modules" am: 26ab0f1051 am: 076ed3bca3 am: fccf62ed45
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1538625

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7842f59026d63a2aab8efe354cc37f20ee9e39ab
2021-01-07 03:16:17 +00:00
Jooyung Han
fccf62ed45 Merge "Add "aidl.flags:" property for cc_/java_ modules" am: 26ab0f1051 am: 076ed3bca3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1538625

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I040864a9f24805fc9d3f8ad426e72566be1fb7eb
2021-01-07 02:25:31 +00:00
Jooyung Han
26ab0f1051 Merge "Add "aidl.flags:" property for cc_/java_ modules" 2021-01-07 01:28:47 +00:00
Bob Badour
a163fe55f9 Merge changes from topic "revert-1377717-metalics-BOEMJWNSHV" am: a1b87c81ca am: 72b5c0288a am: 15ef54bab8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1541852

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I917681ef203a9974b958ef1086f4e8e161cb7baa
2021-01-06 20:22:46 +00:00
Bob Badour
15ef54bab8 Merge changes from topic "revert-1377717-metalics-BOEMJWNSHV" am: a1b87c81ca am: 72b5c0288a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1541852

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie75ae43eb4e19104a2d7702819de6ab57a97bf5b
2021-01-06 20:01:12 +00:00
Bob Badour
5293a09d57 Export soong license data to make. am: 74fab31712 am: de77ecd56b am: 0b061c969c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1454916

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6decb1f33ea120a79a8de2c5b26dd4d87db627d3
2021-01-06 19:54:08 +00:00