Commit Graph

5623 Commits

Author SHA1 Message Date
Treehugger Robot
9a4279309f Merge "Update soong copy of java binaries when Make copy is installed" 2021-02-23 21:35:20 +00:00
Treehugger Robot
7eacdbf8a6 Merge "Add non-fatal mode for verify_uses_libraries check." 2021-02-23 20:45:42 +00:00
Colin Cross
44b85d01c9 Update soong copy of java binaries when Make copy is installed
m <modulename> is handled by Make and installs the Make copy of a host
java binary in out/host/linux-x86/bin, and doesn't depend on the Soong
copy in out/soong/host/linux-x86/bin.  That can leave a stale binary
in the Soong directory, and since the Soong directory is first in the
path set up by envsetup.sh, can result in confusing behavior to end
users.

cc_binary already has the Make binary depend on the Soong binary
so that they are both updated.  Do the same for java_binary.

Fixes: 180405155
Test: m metalava
Change-Id: Ic84a131a2851cc4a18ce3725da3c4067137d6120
2021-02-23 11:19:57 -08:00
Paul Duffin
ece454400d Merge changes from topic "hiddenapi_additional_annotations"
* changes:
  Sort hiddenapi monolithic files by signature
  Remove duplicates in monolithic hidden API files
  Remove implicit dependency from <x> -> <x>-hiddenapi
2021-02-23 12:48:24 +00:00
Treehugger Robot
f41b2ab648 Merge "Fix infinite recursion when printing unrecognized linktype" am: f0f152484b am: 2cf358677b am: 98f5b4b6e0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1600834

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I53ea29450f59496f10a896d3712a32c044102efe
2021-02-23 10:22:29 +00:00
Treehugger Robot
98f5b4b6e0 Merge "Fix infinite recursion when printing unrecognized linktype" am: f0f152484b am: 2cf358677b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1600834

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I9d51880f8ccdbbdc5f281e182f987f543b4b3ed2
2021-02-23 08:42:44 +00:00
Colin Cross
24bdd3ae4f Merge "Add ArcSettings and SettingsGoogle to the legacy allowlist" into rvc-qpr-dev-plus-aosp 2021-02-23 04:12:51 +00:00
Colin Cross
e8c07c5c54 Merge changes from topic "SettingsGoogle-bp-rvc-qpr-dev-plus-aosp" into sc-dev
* changes:
  Add ArcSettings and SettingsGoogle to the legacy allowlist 2p: fdc78fd88d
  Add ArcSettings and SettingsGoogle to the legacy allowlist
2021-02-23 04:12:51 +00:00
Jiyong Park
d4cbf34032 Fix infinite recursion when printing unrecognized linktype
Bug: N/A
Test: remove some cases from String() so that some linktypes go to the
default path. Then run m nothing. No infinite recursion. Error is
correctly shown.
PANIC=String method: unrecognized linktype: 5
Change-Id: I424755bc89871fc2144ff22d6391f57157cd434d

Change-Id: Ice791025dc50f44ffabd1050bafc5ea35023d32c
2021-02-23 04:02:23 +00:00
Treehugger Robot
d1abafe830 Merge "Limit the number of the Java source files in a single compilation unit" am: a61a042fa6 am: 3e97f39674 am: 398253b55c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1590694

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If636ff3863b1b81256abd20bd139160bfd56aedc
2021-02-23 02:21:19 +00:00
Treehugger Robot
173eeb8ca0 Merge "Add ctx to AndroidMkExtraEntriesFunc" am: 277303f042 am: 5b72de988f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1360943

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I90ae8f53df60dd6bdbc9ae040c44a28a334017e3
2021-02-23 01:45:26 +00:00
Treehugger Robot
398253b55c Merge "Limit the number of the Java source files in a single compilation unit" am: a61a042fa6 am: 3e97f39674
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1590694

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I887bfca8ce13ced6aa4005afa97a8c7e425716b4
2021-02-23 01:45:06 +00:00
Treehugger Robot
277303f042 Merge "Add ctx to AndroidMkExtraEntriesFunc" 2021-02-22 22:40:31 +00:00
Presubmit Automerger Backend
342efcad1c Add ArcSettings and SettingsGoogle to the legacy allowlist 2p: fdc78fd88d
Original change: https://googleplex-android-review.googlesource.com/c/platform/build/soong/+/13630298

Change-Id: I64e8a715538f8515254368ec427bdb6cb1ff996d
2021-02-22 21:44:32 +00:00
Treehugger Robot
a61a042fa6 Merge "Limit the number of the Java source files in a single compilation unit" 2021-02-22 19:54:00 +00:00
Ulya Trafimovich
8c35fcf4d5 Add non-fatal mode for verify_uses_libraries check.
The new mode is enabled with environment variable
RELAX_USES_LIBRARY_CHECK. If the variable is set to true, then a
verify_uses_libraries check failure does not fail the build, instead it
sets a special compiler filter "extract" for dexpreopt, which means that
the DEX file will be extracted, but it won't be compiled to native code.
Class loader context will be set to empty in this case (not &, as it is
going to be deprecated soon).

If the variable RELAX_USES_LIBRARY_CHECK is unset or set to something
other than "true", then the old behaviour of the verify_uses_libraries
check is preserved.

The intended use case for this flag is to have a smoother migration path
for the Java modules that need to add <uses-library> information in
the build files. The flag allows to quickly silence build errors. This
flag should be used with caution and only as a temporary measure, as it
masks real errors and affects performance.

verify_uses_libraries check is reworked so that it writes the error
message to a status file (which is used instead of the former timestamp
file). Currently the stored error message is not used, but it may be
used later to produce a warning. Dexpreopt command checks if the status
file exists and is nonempty; if that is the case, then compiler filter
is set to "extract".
Bug: 132357300

Test: Manually add some mismatch between the libraries in the Android.bp
      and Android.mk files for dexpreopted apps, build with
      RELAX_USES_LIBRARY_CHECK=true and obsserve that the build doesn't
      fail and they are compiled with compiler-filter "extract".
      Unset RELAX_USES_LIBRARY_CHECK and observe that the build fails.

Change-Id: Ibb5d993a25b1df1d2e70b7d5aafc6997f9d64e67
2021-02-22 15:41:03 +00:00
Christoffer Quist Adamsen
e850737ee4 Allow missing classes in R8 builds
Bug: 180878971
Bug: 72683872
Test: TARGET_PRODUCT=aosp_arm64 m -j core-oj
Change-Id: I663220567eb8f034d3efccc60228aef91c716e8e
2021-02-22 12:09:01 +00:00
Treehugger Robot
c5b87bdc4b Merge "Remove EnforceRROExemptedTargets" am: f0a869847a am: 7a7c1491c4 am: a9cf772572
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1596231

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I61fd5f110aefd4f3ba2b79219f40a66251464117
2021-02-20 04:07:41 +00:00
Treehugger Robot
a9cf772572 Merge "Remove EnforceRROExemptedTargets" am: f0a869847a am: 7a7c1491c4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1596231

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic7fc17dd2f173a1e28509012b4eb7c8bc3872c43
2021-02-20 03:24:59 +00:00
Treehugger Robot
f0a869847a Merge "Remove EnforceRROExemptedTargets" 2021-02-20 01:47:43 +00:00
Colin Cross
aa2555387d Add ctx to AndroidMkExtraEntriesFunc
Add a ctx parameter to AndroidMkExtraEntriesFunc to allow them to
access providers.

Test: m checkbuild
Change-Id: Id6becc1e425c3c3d8519248f8c0ce80777fac7cc
Merged-In: Id6becc1e425c3c3d8519248f8c0ce80777fac7cc
2021-02-19 23:05:40 +00:00
Colin Cross
fdc78fd88d 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.

This relands I73bef76ecc517223827ac6f3cb1f0624c738fb9d.

Bug: 175124789
Change-Id: I6e116b5d4574990c8513371bbbb5175f2516c98f
Test: m RunSettingsGoogleRoboTests RunArcSettingsRoboTests
2021-02-19 19:18:41 +00:00
Jeongik Cha
cee5ba973d Remove EnforceRROExemptedTargets
There is no more target relying on EnforceRROExemptedTargets

Bug: 150820813
Test: m
Change-Id: If50d22c0e4f99e8c50d6a30cb94a0c3a5646b6fa
2021-02-19 12:16:12 +09:00
TreeHugger Robot
bd72625520 Merge "Add ctx to AndroidMkExtraEntriesFunc" into sc-dev 2021-02-19 01:03:10 +00:00
Pedro Loureiro
c14cf5825c Merge "Add support for lint baseline files" am: 8a75058d3f am: 85c97f861a am: 2464363376
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1589498

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7cb9ba83444af9df321adb9b8b16adeb2157a67e
2021-02-18 17:13:34 +00:00
Pedro Loureiro
2464363376 Merge "Add support for lint baseline files" am: 8a75058d3f am: 85c97f861a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1589498

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I4a43fdd2881f47d00611e9cf5c145100d996e135
2021-02-18 16:52:26 +00:00
Treehugger Robot
d061be5058 Merge "Further simplify the link type check routine" am: ca52bfcf0f am: 48d587d67a am: 3d23a56d6b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1593592

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I58f163e3c9520cb7d93cb097e10eaac5ee690280
2021-02-18 16:20:57 +00:00
Jiyong Park
2f04e04502 Merge "Linktype check error message becomes more correct" am: 4941e4b9d1 am: 4de1a5651f am: 605bc52821
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1593811

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I6158deb212cd32e2f41a5484376a6791cfca2460
2021-02-18 16:20:01 +00:00
Pedro Loureiro
8a75058d3f Merge "Add support for lint baseline files" 2021-02-18 15:53:13 +00:00
Treehugger Robot
3d23a56d6b Merge "Further simplify the link type check routine" am: ca52bfcf0f am: 48d587d67a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1593592

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I545f48aac7a1bf76973b3e05b289590e9c039286
2021-02-18 15:49:26 +00:00
Jiyong Park
605bc52821 Merge "Linktype check error message becomes more correct" am: 4941e4b9d1 am: 4de1a5651f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1593811

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3f9b8a7add946d82ea2adecc53ffc44176aea01f
2021-02-18 15:46:44 +00:00
Treehugger Robot
ca52bfcf0f Merge "Further simplify the link type check routine" 2021-02-18 13:54:27 +00:00
Jiyong Park
4941e4b9d1 Merge "Linktype check error message becomes more correct" 2021-02-18 11:32:03 +00:00
Jiyong Park
7f87e1ab49 Further simplify the link type check routine
Bug: 180477804
Test: m nothing
Change-Id: I216be96cf844fe42ba0cec467eea8520ff4ef4f2
2021-02-18 20:29:05 +09:00
Pedro Loureiro
5d190cc24e Add support for lint baseline files
Test: m droid
Test: go test ^TestJavaLint # (from soong/build/java)

Change-Id: I249a0a0597b0bf8495460ed283b476ad2eb36edc
2021-02-18 11:15:30 +00:00
Anton Hansson
3b8a42e601 Merge "Use genrule instead of filegroup for api files" am: 3de06eae5b am: e223268ed8 am: 9b74b06e65
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1592331

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I71d2c8582bd5d8e1651c8df5971354024dbc5e2b
2021-02-18 10:48:42 +00:00
Martin Stjernholm
c4a1ede482 Merge "Move the logic to add jacocoagent in instrumentation builds to make." am: 71c139dced am: 2eed280a39 am: dd34be43f1
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1592232

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I86b1c559c714826a4fa4d4ae47ab85d07322715f
2021-02-18 10:48:29 +00:00
Anton Hansson
9b74b06e65 Merge "Use genrule instead of filegroup for api files" am: 3de06eae5b am: e223268ed8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1592331

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: If3e7f7af46b93dd25fb5eca1e820bf32b2e1144c
2021-02-18 10:43:19 +00:00
Anton Hansson
3de06eae5b Merge "Use genrule instead of filegroup for api files" 2021-02-18 09:28:01 +00:00
Martin Stjernholm
dd34be43f1 Merge "Move the logic to add jacocoagent in instrumentation builds to make." am: 71c139dced am: 2eed280a39
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1592232

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I526b557a0e82d2b953b0b603ae8b2a5dc9bcba95
2021-02-18 09:06:43 +00:00
Jiyong Park
670e0f62a6 Linktype check error message becomes more correct
The type linkType has String() method and the error message is created
using it.

Bug: 180477804
Test: m nothing
Change-Id: I74fe9c93b74904177dbe9d29cd3aa3304b67ba4f
2021-02-18 13:10:18 +09:00
Colin Cross
f79fee864c Add ctx to AndroidMkExtraEntriesFunc
Add a ctx parameter to AndroidMkExtraEntriesFunc to allow them to
access providers.

Bug: 180540739
Test: m checkbuild
Change-Id: Id6becc1e425c3c3d8519248f8c0ce80777fac7cc
2021-02-17 15:24:43 -08:00
Ulyana Trafimovich
92dac721f6 Revert^3 "Enforce <uses-library> checks for android_app and android_app_import."
This reverts commit c2b6b65d73.

Reason for revert: These changes should only be reverted in
  rvc-qpr-dev-plus-aosp, but not in master.

Bug: 132357300
Test: treehugger
Change-Id: I3243668ce9a399936b0e9dde09c42db6cc45d562
2021-02-17 18:13:33 +00:00
Anton Hansson
c79d412b8a Use genrule instead of filegroup for api files
filegroups have the unfortunate limitation that they don't create phony
targets for building them in a convenient way. Also, having a single
output file fits better with the genrule concept.

Test: m framework-sdkextensions.api.public.latest
Change-Id: I229410658b04403ff1ff6abd4116a65aaa02b83b
2021-02-17 17:16:43 +00:00
Martin Stjernholm
0a9dae6e9a Move the logic to add jacocoagent in instrumentation builds to make.
Test: m nothing
Test: m nothing EMMA_INSTRUMENT=true EMMA_INSTRUMENT_FRAMEWORK=true
Bug: 180325915
Change-Id: Ieec8c8a122ff930e14cef4b5a0a2f9fc9e3b70ad
2021-02-17 14:41:07 +00:00
Jiyong Park
7d43709811 Revert "data dependency of java_test_host can be arch-specific" am: 2b0e4908c2 am: 4362e740af am: 1cea07c8ab
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1588300

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I25b7c1b75a28247ce220fc09b50d9faa96b90fc1
2021-02-17 00:45:48 +00:00
Jiyong Park
1cea07c8ab Revert "data dependency of java_test_host can be arch-specific" am: 2b0e4908c2 am: 4362e740af
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1588300

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I2e78f3d281517016afeb7b24d5dd1b8249124183
2021-02-17 00:25:41 +00:00
Jiyong Park
4362e740af Revert "data dependency of java_test_host can be arch-specific" am: 2b0e4908c2
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1588300

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iae42079a404a59730f2eb622fa39d462610f0c50
2021-02-16 23:54:29 +00:00
Treehugger Robot
b913011777 Merge changes from topic "mkboot"
* changes:
  prebuilt_etc is OutputFileProducer
  Revert "`data` dependency of java_test_host can be arch-specific"
2021-02-16 23:27:32 +00:00
Sasha Smundak
b0addafd93 Limit the number of the Java source files in a single compilation unit
KYTHE_JAVA_SOURCE_BATCH_SIZE environment variable controls this setting.
The limit is 1000 if this variable is not set.

Fixes: 179932118
Test: run prebuilts/build-tools/build-prebuilts.sh, use it to build kzips, check
Change-Id: I9ad57dfd1d2c2dce5cff755b1bd61cf933420bd3
2021-02-16 15:14:52 -08:00