Commit Graph

33339 Commits

Author SHA1 Message Date
Ryan Prichard
471dfd6809 Merge "Switch platform EH unwinder to prebuilt LLVM libunwind" am: 809eac3057 am: 048809c624
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551580

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8d3ced17f7aadbc27498a89eedc2b9f8df9f4a3c
2021-01-20 01:53:10 +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
Ryan Prichard
048809c624 Merge "Switch platform EH unwinder to prebuilt LLVM libunwind" am: 809eac3057
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551580

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iec876d769dd1a5370069650c322445e314379127
2021-01-20 00:44:05 +00:00
JaeMan Park
4198b5c05a Merge "Make TestJavaSdkLibraryEnforce faster" am: cdbbb1ea68
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549896

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7e834445708aedf78cb3a1e64affe3be5d963968
2021-01-20 00:41:51 +00:00
Ryan Prichard
809eac3057 Merge "Switch platform EH unwinder to prebuilt LLVM libunwind" 2021-01-20 00:10:59 +00:00
JaeMan Park
cdbbb1ea68 Merge "Make TestJavaSdkLibraryEnforce faster" 2021-01-20 00:00:54 +00:00
Treehugger Robot
6489368645 Merge "Implement code-generation step for bp2build." am: de1357378b am: e652936aac
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1527838

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic8e0277b617007eecf16d3cfed214f208408698c
2021-01-19 19:21:33 +00:00
Treehugger Robot
e652936aac Merge "Implement code-generation step for bp2build." am: de1357378b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1527838

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If317f9a9df8edf99b704c75acdbd710e3875a422
2021-01-19 18:35:18 +00:00
Treehugger Robot
de1357378b Merge "Implement code-generation step for bp2build." 2021-01-19 17:41:59 +00:00
Jingwen Chen
daa54bcbba Implement code-generation step for bp2build.
Implement bp2build codegen as a discrete step that runs after an
alternatively registered pipeline of mutators, instead of a
presingleton.

bp2build codegen requires a Context that supports VisitAllModules and
PathContext, so this CL also makes a BpToBuildWrapperContext that
conforms to PathContext by adding two method implementations.

Test: GENERATE_BAZEL_FILES=true m nothing && bazel query //... --config=bp2build | wc -l # 31433
Test: m queryview && bazel query //... --config=queryview # 63638

Change-Id: I0dd359746584b228046d2d0ff00895f28f9bdfc3
2021-01-19 11:03:36 -05:00
Christopher Parsons
37ba82217d Merge "Improve aquery-related validation and error handling" am: ad3421aacf am: 3f4738431b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553034

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I990796cd78d1eafc345bdcbfb57fb26929b94c23
2021-01-19 15:56:30 +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
Christopher Parsons
3f4738431b Merge "Improve aquery-related validation and error handling" am: ad3421aacf
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553034

MUST ONLY BE SUBMITTED BY AUTOMERGER

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

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I356a0f75453bfdfc8db166227a875dec25aa4ab6
2021-01-19 15:11:09 +00:00
Christopher Parsons
ad3421aacf Merge "Improve aquery-related validation and error handling" 2021-01-19 14:59:51 +00:00
Paul Duffin
fe6147eb26 Merge "Export dex implementation jars from prebuilt_apex" 2021-01-19 14:34:29 +00:00
Treehugger Robot
354889fb3a Merge "Remove unused parameter to newContext." am: 0e3aaa47aa am: 9222ce0be5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1552083

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic9717473660482c01f51bcee4c8f80d51aa41dd3
2021-01-19 14:11:27 +00:00
Treehugger Robot
9222ce0be5 Merge "Remove unused parameter to newContext." am: 0e3aaa47aa
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1552083

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4a910654fee12a3e31d4394a1bef0fe5599d6366
2021-01-19 13:35:57 +00:00
Treehugger Robot
0e3aaa47aa Merge "Remove unused parameter to newContext." 2021-01-19 13:10:28 +00:00
Inseob Kim
5aad938c10 Merge "Allow sysprop library API files to be missing" am: f61dfa5a02 am: 1d9f614e98
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1552044

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1847b87390c24fa7716503eb5c4d4816c59ce4c1
2021-01-19 12:40:52 +00:00
Inseob Kim
1d9f614e98 Merge "Allow sysprop library API files to be missing" am: f61dfa5a02
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1552044

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ib56a61293f499d56f372ba47fdad448c158d7272
2021-01-19 11:51:30 +00:00
Inseob Kim
f61dfa5a02 Merge "Allow sysprop library API files to be missing" 2021-01-19 11:24:12 +00:00
Jingwen Chen
09b609d476 Remove unused parameter to newContext.
Test: TH, soong bootstrap tests
Change-Id: Ia7c0fdc2b5d784ef6b389858dab2fcbad35a3763
2021-01-19 04:55:02 -05:00
Chih-Hung Hsieh
a8e4121466 Do not enable all clang-analyzer-* checks, am: 4d31a041c7 am: 1bf2e3f449
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553374

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Id55ab11a229d8d22bce7264a35447c054e0e06e7
2021-01-16 09:57:31 +00:00
Chih-Hung Hsieh
1bf2e3f449 Do not enable all clang-analyzer-* checks, am: 4d31a041c7
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553374

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie2d3ba10dc61759cea321004560a06bb7fff387c
2021-01-16 09:08:02 +00:00
Chih-Hung Hsieh
4d31a041c7 Do not enable all clang-analyzer-* checks,
* clang-analyzer is slow and enables clang-diagnostic-padded,
  which cannot be suppressed yet.

Test: make with WITH_TIDY=1 for crosshatch-userdebug
Change-Id: I20193f0db3154b037d58c5ca012a9e753b176722
2021-01-15 21:10:35 -08:00
Treehugger Robot
a979a9bae7 Merge "add more global default checks" am: 9235fea8c3 am: 52693cd46a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551578

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6f448ab0c1ac66e49ada7a0f772a3f03583ecd56
2021-01-16 01:50:31 +00:00
Treehugger Robot
1f367ef490 Merge "WITH_TIDY=1 implies -warnings-as-errors=-*" am: 2207565b43 am: b42947cba0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551577

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9b722d80496fab9a41d5a58975b51e397e08ce97
2021-01-16 01:48:21 +00:00
Treehugger Robot
52693cd46a Merge "add more global default checks" am: 9235fea8c3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551578

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie87dcfa735db1b56cce50044bd0220cde5a38e29
2021-01-16 01:32:34 +00:00
Treehugger Robot
b42947cba0 Merge "WITH_TIDY=1 implies -warnings-as-errors=-*" am: 2207565b43
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551577

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ia62118358cbbc7c318d6be86c25441aeb6dbd040
2021-01-16 01:27:49 +00:00
Treehugger Robot
9235fea8c3 Merge "add more global default checks" 2021-01-16 01:24:05 +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
Treehugger Robot
2207565b43 Merge "WITH_TIDY=1 implies -warnings-as-errors=-*" 2021-01-16 00:37:34 +00:00
Treehugger Robot
34309dcaa9 Merge "Add java_boot_libs to sdk" am: 2b72906ade
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1526699

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ieeac27c51314a60f4778bc864e456aeed5a54359
2021-01-16 00:04:19 +00:00
Treehugger Robot
2b72906ade Merge "Add java_boot_libs to sdk" 2021-01-15 23:33:13 +00:00
Chih-Hung Hsieh
34850d350e add more global default checks
Test: make with and without WITH_TIDY=1
Change-Id: Iee07707158f7204e961970ba4d518403b3b2aaf3
2021-01-15 14:31:13 -08:00
Chih-Hung Hsieh
1b4934a215 WITH_TIDY=1 implies -warnings-as-errors=-*
* This allows local projects to enable clang-tidy
  and catch errors in a default build, but allows
  all warnings in a global build with WITH_TIDY=1.

Test: make with WITH_TIDY=1
Change-Id: I92a10af24b23ee9f04eebb0513e8f611dd7dcf59
2021-01-15 14:17:39 -08:00
Chris Parsons
4f069891ae Improve aquery-related validation and error handling
Also introduce test suite for aquery handling

Test: m nothing
Test: lunch aosp_flame && USE_BAZEL_ANALYSIS=1 m libc
Change-Id: I2493d42782099ea0b575968fca38bce6f0d59015
2021-01-15 13:53:57 -05:00
Colin Cross
06cf6e723c Merge "manifest_fixer: Set targetSdkVersion to '16' for libraries" am: 0dd19125eb am: 3f1db8cc00
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549338

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6c892b62af25d101982e341348ba257dedbd6a16
2021-01-15 18:53:17 +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
Colin Cross
3f1db8cc00 Merge "manifest_fixer: Set targetSdkVersion to '16' for libraries" am: 0dd19125eb
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549338

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie5c8f96b1323c257797d4041dffbee2a0f54a75f
2021-01-15 18:00:21 +00:00
Colin Cross
0dd19125eb Merge "manifest_fixer: Set targetSdkVersion to '16' for libraries" 2021-01-15 17:13:31 +00:00
Inseob Kim
c9770d6a9c Allow sysprop library API files to be missing
If sysprop library contains only internal properties, the API txt file
will be empty. This allows the API files to be missing in such cases to
turn off API-Review bit.

Bug: 177036449
Test: manual test
Change-Id: I8cb0b10e135cf211dae45ab14ccc9bc04e248634
2021-01-15 18:10:05 +09: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
Treehugger Robot
91cf763bfd Merge "Adjust the double loadable check" am: b47dcf7f0d am: fc76f2cb9d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1550398

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iec20af756d9430f708ec0bbbc3a9d25ccb103e15
2021-01-15 04:02:26 +00:00
Treehugger Robot
fc76f2cb9d Merge "Adjust the double loadable check" am: b47dcf7f0d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1550398

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ida87cbc7706b2f280192e3bd53f736a4afe69b03
2021-01-15 03:34:11 +00:00
Treehugger Robot
b47dcf7f0d Merge "Adjust the double loadable check" 2021-01-15 02:22:09 +00:00
Treehugger Robot
42ea9996d0 Merge "Must use vendor variant for health storage AIDL HAL" am: ee8ae11c0f am: 87328318cc
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549747

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Idf860f52a6fda19fd2328e1b642a5ab014113b56
2021-01-14 22:45:34 +00:00
Chris Li
ff8118fe9d Revert "To use same default for the nightly builds." am: 46cad069d1 am: 61316dbda6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549528

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ifd3b9a1c79e91eb81dc0637caff384531004f7fd
2021-01-14 22:45:15 +00:00