Commit Graph

6123 Commits

Author SHA1 Message Date
Inseob Kim
0c9e1d388d Merge "Truncate vendor snapshot header glob list after filtering it" am: ec7cab81f9 am: 249609366d am: cb6d9b1d29
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1555161

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ie569526241f5e1b59caa3505422f34e45bfeb0b0
2021-01-21 07:56:04 +00:00
Inseob Kim
c98399e60f Merge "Speed up vendor snapshot header globs" am: ab15f9644b am: 9a7f405bc9 am: ee3791b9f4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1554550

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I76b8036af1266c565e0ad79c59c6094dc9877f2a
2021-01-21 02:10:42 +00:00
Colin Cross
3a62a9cc2b Truncate vendor snapshot header glob list after filtering it
Test: m checkbuild
Change-Id: I4847bff5c03844194a9a80e8cb24a60694db6208
2021-01-21 00:46:46 +00:00
Evgenii Stepanov
04896cae35 Support memtag_heap in SANITIZE_TARGET_DIAG, fix cc_test interation.
cc_test without sanitize:memtag_heap acts as if it has implicit
sanitize{memtag_heap:true, diag:{memtag_heap:true}}. This is unaffected
by SANITIZE_TARGET.

Refactor the test to cover all permutations.

Change memtag include lists to act similar to SANITIZE_TARGET_DIAG: the
the sync include list upgrades async targets to sync, unless diag is
explicitly set to false in the target definition.

Bug: b/135772972
Test: cc_test.go

Change-Id: I6a969f2f5804cd5f47fc4e93a20e3b99ea5fa111
2021-01-20 22:27:45 +00:00
Colin Cross
217f7b33c4 Merge "Don't create SDK variants for native bridge modules" am: bdeafb93fd am: f5cd3722cf am: 5459575558
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553881

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iacbd8783289feed7aa810da0f0c7635067e73863
2021-01-20 19:46:58 +00:00
Colin Cross
0f93e5b9fb Speed up vendor snapshot header globs
The vendor snapshot header globs were repeated 9 times, once for each
possible header suffix.  Globbing is not a fast operation, so this
took 9.68s of CPU time in my AOSP builds.  Replace it instead with a
single glob, followed by filtering down to the desired header
extensions.

Test: m checkbuild
Change-Id: I9c8f8cdad8cbffc0a42217659a48dd9d676e4e4c
2021-01-20 18:36:25 +00:00
Colin Cross
08117deab4 Fix mismatch between cc and python for windows prefer32
Windows prefer32 was implemented in cc, which caused a mismatch
between cc and other packages like python.  This manifested as
missing variant when a python_test_host with compile_multilib: "first"
tried to depend on a cc_binary_host, which implicitly has multilib
"first".

Fixes: 177904375
Test: m checkbuild
Change-Id: Iaaac16ae171c06d90d04d7cac11789d3f39b8d99
2021-01-20 10:26:00 -08:00
Cindy Zhou
0ae13ec307 Merge "Build against cfi supported coverage lib" 2021-01-20 18:08:30 +00:00
Colin Cross
bdeafb93fd Merge "Don't create SDK variants for native bridge modules" 2021-01-20 17:49:36 +00:00
Chih-Hung Hsieh
9170f0f2c4 Add clang-analyzer check if selected. am: 04f8d379e6 am: 6b6b7353f8 am: dee5011892
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1554894

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Iaa5585831e6b61a6d62d2e37b8383e3ea7b100de
2021-01-20 08:46:41 +00:00
Chih-Hung Hsieh
04f8d379e6 Add clang-analyzer check if selected.
* WITH_TIDY=1 should not include clang-analyzer-* checks
  because they are too slow.
* Nightly builds will use both WITH_TIDY=1 and
  CLANG_ANALYZER_CHECKS=1.

Bug: 173736193
Test: make with WITH_TIDY=1 and CLANG_ANALYZER_CHECKS=1
Change-Id: I3885fd0e20475ceee5e3798bffc11a61994ac113
2021-01-19 19:21:39 -08:00
Inseob Kim
7577c1eb1c Merge "Implement directed vendor snapshot" am: 9bd66d1537 am: bc657cb78a am: dcebff8f67
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1541208

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I1c4870fa350bfe767019a0103d619b9e01c20c87
2021-01-20 02:16:15 +00:00
Inseob Kim
6a993709d4 Merge "Refine sysprop_library header rules" am: 4c4de0edc3 am: 1ee0c0c4ba am: b904808ac6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553459

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ifcd813e9ae13863a4a5118130da416c30b6ef62c
2021-01-20 02:16:09 +00:00
Ryan Prichard
6761a5eeae Merge "Switch platform EH unwinder to prebuilt LLVM libunwind" am: 809eac3057 am: 048809c624 am: 471dfd6809
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551580

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I93276241d217b7d2ebdffa58abb60d2d0721c672
2021-01-20 02:15:55 +00:00
Inseob Kim
9bd66d1537 Merge "Implement directed vendor snapshot" 2021-01-20 01:17:25 +00:00
Inseob Kim
4c4de0edc3 Merge "Refine sysprop_library header rules" 2021-01-20 01:17:22 +00:00
Ryan Prichard
809eac3057 Merge "Switch platform EH unwinder to prebuilt LLVM libunwind" 2021-01-20 00:10:59 +00:00
Colin Cross
94e347e6a5 Don't create SDK variants for native bridge modules
Native bridge modules never need to build against NDK stubs, so
don't create SDK variants.  Also clear the sdk_version property
for modules that don't have SDK variants so that later code doesn't
use it to trigger SDK behaviors.

Test: m checkbuild
Change-Id: I1920fa82e9fab06235f01a62624382efa16cc6e3
2021-01-19 15:00:45 -08:00
Inseob Kim
7cf1465d2e Implement directed vendor snapshot
Vendors can now generate only needed modules by setting the following
Makefile variables:

- DIRECTED_VENDOR_SNAPSHOT: set to true
- VENDOR_SNAPSHOT_MODULES: list of snapshot candidates

e.g.

DIRECTED_VENDOR_SNAPSHOT := true
VENDOR_SNAPSHOT_MODULES := toybox_vendor sh_vendor libbase libcutils ...

Bug: 157967325
Test: m dist vendor-snapshot after setting those in BoardConfig.mk
Change-Id: I6515a43d9358d94483d7c7fa2b066f9dd457f6aa
2021-01-18 20:08:09 +09:00
Inseob Kim
0641004a3f Refine sysprop_library header rules
Instead of unreliable giant if clause, it's enough to check dependency
between platform (system, system-ext), product, and vendor.

Test: sysprop_test soong test
Test: link against host_supported sysprop_library and use internal props
Change-Id: I7bd5df00b302fa261eff5120106aacc3df93c1b2
2021-01-18 15:23:28 +09:00
Chih-Hung Hsieh
40891da084 Do not enable all clang-analyzer-* checks, am: 4d31a041c7 am: 1bf2e3f449 am: a8e4121466
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1553374

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I7ad24a1cd9c755dcfda34319dece88bfe3ae9a74
2021-01-16 10:18:29 +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
6b15f92d95 Merge "add more global default checks" am: 9235fea8c3 am: 52693cd46a am: a979a9bae7
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1551578

MUST ONLY BE SUBMITTED BY AUTOMERGER

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

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I8bd5167d67b5db463873b47bf063af24d223747a
2021-01-16 01:54:30 +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
Treehugger Robot
b0d869e24f Merge "Adjust the double loadable check" am: b47dcf7f0d am: fc76f2cb9d am: 91cf763bfd
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1550398

MUST ONLY BE SUBMITTED BY AUTOMERGER

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

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I26754f095e1016bf30b27f8a1308ed36a8e42ecc
2021-01-15 14:08:20 +00:00
Colin Cross
da0330646b Merge "Remove global state from VNDK" am: 6c0a9f69e9 am: 6b937be368 am: 4e96d84d64
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1542205

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I013b68f54adae6f9ad45e87320ce9ec7477f95d9
2021-01-15 14:04:07 +00:00
Janis Danisevskis
7dde1e4004 Merge "The build related changes for Secure Clock and Shared Secret functionalities." am: 0ce3a40bf8 am: 3b55e031cd am: cf4ad11544
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1519849

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ic597e60c0fe3ccad109aed17d45783a811166e56
2021-01-15 13:55:17 +00:00
Treehugger Robot
b47dcf7f0d Merge "Adjust the double loadable check" 2021-01-15 02:22:09 +00:00
Jiyong Park
423e37873b API availability should be checked using __builtin_available
This change turns -Wunguarded-availability option which enforces calls
to APIs which are introduced after the min_sdk_version of the
compliation unit to be guarded with __builtin_available check. For
example, let's assume that we have foo() which was introduced with API
level 30.

void foo() __INTRODUCED_IN(30);

Then if foo() is called for a module whose min_sdk_version is less than
30, say 26, it should be called as below:

if (__builtin_available(android 30, *)) {
  foo();
} else {
  // fallback impl
}

For modules whose min_sdk_version is >=30, the guard is not required.

Bug: 150860940
Bug: 134795810
Test: m

Change-Id: I084148b9a051350626a37cb394daa4398b7332d5
2021-01-15 09:43:35 +09:00
Treehugger Robot
ee8ae11c0f Merge "Must use vendor variant for health storage AIDL HAL" 2021-01-14 22:22:08 +00:00
Chris Li
46cad069d1 Revert "To use same default for the nightly builds."
This reverts commit b063dc4221.

Reason for revert: DroidMonitor-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?branch=git_master&target=crosshatch-userdebug&lkgb=7080774&lkbb=7082597&fkbb=7080869, bug 177549474

Test: make
Change-Id: I8b6cf3b56fddde9832e1428a3d1aef00f19637fb
2021-01-14 13:37:54 -08:00
Yifan Hong
59d876d69b Merge "Must use vendor variant for health storage AIDL HAL" 2021-01-14 20:32:55 +00:00
Cindy Zhou
5d5cfc164d Build against cfi supported coverage lib
The change will detect if a module is compiled against cfi support, and
will usebuild the coverage build against the libprofile that supports cfi. This is to resolve compilation errors when
building against modules with cfi support.
Bug: 177098919
Test: forrest build for cf_x86_phone-userdebug_coverage http://go/forrest-run/L81700000786828933

Change-Id: I8e0421cdf1c6e499292cfa3457cefd3c42f13155
Merged-In: I8e0421cdf1c6e499292cfa3457cefd3c42f13155
2021-01-14 11:46:10 -08:00
Colin Cross
6c0a9f69e9 Merge "Remove global state from VNDK" 2021-01-14 18:31:06 +00:00
Janis Danisevskis
0ce3a40bf8 Merge "The build related changes for Secure Clock and Shared Secret functionalities." 2021-01-14 18:04:02 +00:00
Jiyong Park
0474e1f677 Adjust the double loadable check
The check no longer tracks private dependencies like stubImplDepTag and
staticVariantTag. It also doesn't do the check for double_loadable
libraries that are not depended on by a LLNDK library.

Bug: N/A
Test: m
Test: add 'double_loadable: true, gen_trace: true` to an aidl_interface
module. The build doesn't break.

Change-Id: Iccd1a9d445a48d03c373708ba1bdd34b9a7f152d
2021-01-14 18:29:47 +09:00
Chih-Hung Hsieh
a66a988708 Fix comment. am: b767f913f1 am: 94bdb905c9 am: 575999b9cb
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1549745

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ib964ff78ad7dce355985e3489b5e884026b6536e
2021-01-14 09:05:12 +00:00
Ryan Prichard
b35a85ee8b Switch platform EH unwinder to prebuilt LLVM libunwind
For the platform libc++ STL, remove the
-Wl,--exclude-libs,libunwind_llvm.a argument, which is redundant with
the same argument in deviceGlobalLdflags.

Bug: http://b/153025717
Test: device boots
Change-Id: Idd7791d52f74aab2d5f59419fb75f841fc29a2eb
2021-01-13 19:51:06 -08:00
Colin Cross
7821224d8e Remove global state from VNDK
Move the global lists of VNDK modules into boolean properties on the
modules themselves, and use the new SingletonModule functionality
to visit all modules and collect the list of modules with the properties
set.

Bug: 176904285
Test: all soong tests
Test: m checkbuild
Test: compare Soong outputs
Change-Id: Icf7e2f8f190a517d30f0780e98762bc0084ddb24
2021-01-13 16:44:32 -08:00
Yifan Hong
78d0f4880c Must use vendor variant for health storage AIDL HAL
Test: mmma hardware/interfaces/health/storage
Bug: 177470478
Change-Id: Iae8dc547d68ecb528c0eb9684353267c1dd30459
Merged-In: Iae8dc547d68ecb528c0eb9684353267c1dd30459
2021-01-13 16:11:45 -08:00
Yifan Hong
caaef4d275 Must use vendor variant for health storage AIDL HAL
Test: mmma hardware/interfaces/health/storage
Bug: 177470478
Change-Id: Iae8dc547d68ecb528c0eb9684353267c1dd30459
2021-01-13 16:07:37 -08:00
Chih-hung Hsieh
863faf6e6c Merge "To use same default for the nightly builds." am: 66f7fdd1c8 am: 10850c9de7 am: c98dc51ae0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1546617

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I3d49935dc0b7fb70107a2211a7fac2d961643060
2021-01-13 23:01:16 +00:00
Chih-Hung Hsieh
b767f913f1 Fix comment.
Test: make
Change-Id: I6c69549cb873e1d160ec6d590749361dc1a291dd
2021-01-13 13:24:15 -08:00
Chih-hung Hsieh
66f7fdd1c8 Merge "To use same default for the nightly builds." 2021-01-13 21:22:48 +00:00
Orion Hodson
3264c90068 Merge "Remove remaining libnativehelper implicit includes" am: 62555ffa5a am: 02d9f55b5b am: 448a038a4d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1371943

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: Ib9e4a808dc8d72c03232850374708164a08b2915
2021-01-13 07:46:01 +00:00
Orion Hodson
62555ffa5a Merge "Remove remaining libnativehelper implicit includes" 2021-01-13 06:11:03 +00:00
Colin Cross
afeacbb1ce Merge changes Ib29ede45,I1b2bfdfb am: 2bcb4940bb am: 0968f0b55e am: b892007c84
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1541225

MUST ONLY BE SUBMITTED BY AUTOMERGER

Change-Id: I38cdae92656ef4304cda49eb7da36d95e00ef90b
2021-01-12 22:25:08 +00:00