Commit Graph

4662 Commits

Author SHA1 Message Date
Colin Cross
4fbb5e0234 Handle static unwinder in ltoDepsMutator
The implementation before libraryDependencyTag was added failed to
treat the libgcc_unwind dependency as a static library when traversing
dependencies for LTO because it didn't handle staticUnwinderDepTag.

Bug: 162437057
Test: m checkbuild
Change-Id: Iccc96c0daa0379f51eb975c51fd5e8c507a0daba
2020-07-29 13:22:33 -07:00
Colin Cross
370173e0af Expose all shared and header libraries to Make
The implementation before libraryDependencyTag was added failed to
expose some shared or header libraries because it didn't handle the
headerExportDepTag or SharedFromStaticDepTag tags.

Bug: 162437057
Test: m checkbuild
Change-Id: Ie477de70faa31cca8afaa753ea1c0c39586858c7
2020-07-29 13:22:33 -07: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
Jasraj Bedi
bb4511df94 Added write only sanitizer for ASAN and HWASAN
Bug: 162024969
Test: Successfully builds targets for both host and device

"writeonly" flag in SANITIZE_(HOST|TARGET) enables it with "address"
and "hwaddress"

Change-Id: Ia89d43230deef15a67dee09ed015fea14f0717ff
2020-07-29 20:13:53 +00:00
Treehugger Robot
51dba16ce7 Merge "Inclusive fix: Replace sanity with validation in cc.go." am: afb7c1b7e9 am: b04b2e0ca4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374703

Change-Id: I8f2a5ff3578cf625b7615a7957701573185853f9
2020-07-29 14:01:28 +00:00
Treehugger Robot
afb7c1b7e9 Merge "Inclusive fix: Replace sanity with validation in cc.go." 2020-07-29 13:24:15 +00:00
Treehugger Robot
41033816b2 Merge "Update language to comply with Android's inclusive language guidance" am: 0fbbc904b8 am: 3c8b1a91ae
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1374756

Change-Id: Icb90cc103d96654ff3ffa62960ceb368a94b53ad
2020-07-29 08:48:41 +00:00
Treehugger Robot
0fbbc904b8 Merge "Update language to comply with Android's inclusive language guidance" 2020-07-29 08:10:52 +00:00
Treehugger Robot
312390eab6 Merge "Update language to comply with Android's inclusive language guidance" am: c92a48ffa7 am: 8c785bcb64
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1373518

Change-Id: Ie99eb89b902d2dea975fa23fe083550cfdf4232d
2020-07-29 01:45:52 +00:00
Treehugger Robot
c92a48ffa7 Merge "Update language to comply with Android's inclusive language guidance" 2020-07-29 01:12:36 +00:00
Patrice Arruda
807cfd2a99 Inclusive fix: Replace sanity with validation in cc.go.
Bug: b/161896447
Test: "lunch 1" and "m nothing"
Change-Id: Ibaba96149763a55a0ff20c338bb98b6f9a2a12b6
2020-07-28 18:35:53 +00:00
Pirama Arumuga Nainar
296ae444b1 Merge "[cc/sanitize] Add Blocklist property" am: eda8499a3c am: bb77ffc496
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1373516

Change-Id: I73bf9a823b80a58690ddb1ede93dbee7e4635f77
2020-07-28 17:55:46 +00:00
Pirama Arumuga Nainar
eda8499a3c Merge "[cc/sanitize] Add Blocklist property" 2020-07-28 17:21:59 +00:00
Yo Chiang
08fac0c25f Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for
reference

Bug: 161896447
Test: TH
Change-Id: I9bb7178518c3f9dec0fe0a6dbd8d1a8e19a6b495
2020-07-29 01:10:11 +08:00
Treehugger Robot
8eff6a65bc Merge "Rename CFI blocklist files." am: 75117fcdd0 am: 204ffe38e3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1373377

Change-Id: I8233fc5410b4ac5376230764298e388a7b331729
2020-07-28 16:20:34 +00:00
Treehugger Robot
75117fcdd0 Merge "Rename CFI blocklist files." 2020-07-28 15:59:47 +00:00
Colin Cross
9ff5a66f03 Merge changes from topic "revert-1366377-prebuilt_build_tool_make-RMDAHCHNNX" am: 96d4f4550a am: db21367de5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1371195

Change-Id: Ia74d51c6399693526bfe4dd192962698c97810d6
2020-07-28 02:21:15 +00:00
Colin Cross
96d4f4550a Merge changes from topic "revert-1366377-prebuilt_build_tool_make-RMDAHCHNNX"
* changes:
  Revert "Add prebuilt_build_tool to allow genrules to use prebuil..."
  Revert "Switch cc's use of bison and flex to prebuilt_build_tool"
  Revert "Fix builds with absolute OUT_DIR"
2020-07-28 01:52:25 +00:00
Kiyoung Kim
019c1a9034 Merge "Deprecate VNDK-Lite" am: 1b478e57a0 am: b0c5e33791
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1351464

Change-Id: I496f158aaa05ad72bbf6f22985a90a76d7d68bf0
2020-07-28 00:59:00 +00:00
Kiyoung Kim
1b478e57a0 Merge "Deprecate VNDK-Lite" 2020-07-28 00:36:11 +00:00
Pirama Arumuga Nainar
6c4ccca7b7 [cc/sanitize] Add Blocklist property
This will eventually replace the Blacklist property.

Update language to comply with Android’s inclusive language guidance

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

Bug: 161896447
Bug: 162245450
Test: build topic
Change-Id: I3c2609c791c27b8ba3bcb55f79304b78bce1f518
2020-07-27 13:37:05 -07:00
Dan Albert
f740ed01ff Update language to comply with Android's inclusive language guidance
See https://source.android.com/setup/contribute/respectful-code for reference

Bug: 161896447
Test: None
Change-Id: I05f296357c7993088190ef45e49fb8e3a02559d6
2020-07-27 13:21:10 -07:00
Pirama Arumuga Nainar
eb8d403273 Rename CFI blocklist files.
Update language to comply with Android’s inclusive language guidance

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

Bug: 161896447
Test: build
Change-Id: I3de274e58135660e102c276a9822a2ef2cd7cba8
2020-07-27 18:37:48 +00:00
David Su
dd18efd95d Revert "Switch cc's use of bison and flex to prebuilt_build_tool"
Revert submission 1366377-prebuilt_build_tool_make

Reason for revert: breaks build
Reverted Changes:
I20bf062bb:Export prebuilt tools to Make
I4bb526492:Move some prebuilt build tool configs to Soong
I195b68813:Support per-module MakeVars
Ibcb257e7b:Fix dependency loop with flex
I6150f0f39:Switch cc's use of bison and flex to prebuilt_buil...
I6939451b8:Reland "Use genrules to build a consistent awk."
Idee60640f:Add prebuilt_build_tool modules for genrule use
I00893172b:Rename bison to bison_bin
I82c26be1c:Add prebuilt_build_tool to allow genrules to use p...

Change-Id: I1ca553ffe4b09250a441b9bc477c3ba98c6f6549
2020-07-24 21:25:00 +00:00
Jooyung Han
fc22012fac Merge "Fix __ANDROID_SDK_VERSION__=0" am: 3992b7c486 am: b96c02671f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1371677

Change-Id: I97d37b0ace05c038a7f6eee6be672f10ce11ffe4
2020-07-24 02:27:35 +00:00
Jooyung Han
3992b7c486 Merge "Fix __ANDROID_SDK_VERSION__=0" 2020-07-24 02:07:03 +00:00
Dan Willemsen
18e6e2d47e Merge "Revert "Support per-module MakeVars"" am: 1a4ab20c1a am: 1ab5fe458a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1371260

Change-Id: Ia6acfc8e5471ab858049ee9becbba5e3fbe094e2
2020-07-23 22:40:18 +00:00
Dan Willemsen
62462de650 Merge changes from topics "prebuilt_build_tool", "prebuilt_build_tool_make" am: 4ec839a251 am: bef2696b56
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1366377

Change-Id: If49014ca1b19a7522f0d679be77e39fbf1f0a622
2020-07-23 22:39:41 +00:00
Dan Willemsen
03c46e7523 Switch cc's use of bison and flex to prebuilt_build_tool am: d2e291ae5c am: d97bee1578
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1366376

Change-Id: Icaa21d4d240b00368d1acfd9becb367ace4eae82
2020-07-23 22:39:36 +00:00
Dan Willemsen
1a4ab20c1a Merge "Revert "Support per-module MakeVars"" 2020-07-23 21:43:04 +00:00
Dan Willemsen
613564eed4 Revert "Support per-module MakeVars"
This reverts commit 2019658b86.

Reason for revert: broke builds where makefiles were using M4 without depending upon it

Change-Id: I18304246e7a8a8f8c2620dd2c65ed77acd256be2
2020-07-23 21:37:35 +00:00
Dan Willemsen
d97bee1578 Switch cc's use of bison and flex to prebuilt_build_tool am: d2e291ae5c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1366376

Change-Id: I8f28910f1578f3e315ea82c804cdefec6a59d971
2020-07-23 21:25:14 +00:00
Dan Willemsen
4ec839a251 Merge changes from topics "prebuilt_build_tool", "prebuilt_build_tool_make"
* changes:
  Support per-module MakeVars
  Switch cc's use of bison and flex to prebuilt_build_tool
  Add prebuilt_build_tool to allow genrules to use prebuilt tools
2020-07-23 21:10:04 +00:00
Jooyung Han
de34d2375f Fix __ANDROID_SDK_VERSION__=0
__ANDROID_SDK_VERSION__ for a cc module means API level of which the
module should work with.

For APEX variants, it should be apex.min_sdk_version and tracked by the
variable cc.Module.apexSdkVersion.

The variable was set in the wrong place and used uninitialized
sometimes, which results __ANDROID_SDK_VERSION__=0.

Bug: n/a
Test: m
Test: checked build.ninja manually
      => no __ANDROID_SDK_VERSION__=0
Change-Id: Iba532b2c62773983414a061f5291a73363322487
2020-07-23 05:01:56 +00:00
Christopher Parsons
f6540ff785 Merge "Create 'cc_prebuilt_test_library_shared' module type" am: 6b3d9c3fe8 am: a8106ebbfb
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1341895

Change-Id: I8507c61067bae8b3fa3d6059a10801c1a582984d
2020-07-22 18:10:29 +00:00
Christopher Parsons
6b3d9c3fe8 Merge "Create 'cc_prebuilt_test_library_shared' module type" 2020-07-22 17:35:34 +00:00
Chris Parsons
1f6d90f4c7 Create 'cc_prebuilt_test_library_shared' module type
This new module type allows cc_test modules to depend on prebuilt
shared libraries and have them included as data dependencies alongside
the test binary.

Test: Manually verified to facilitate mk-to-bp migration of
bionic-unit-test prebuilt dependencies (aosp/1339035)

Change-Id: Idbac0854f1f9e2e01bbfa63591de458b61733e17
2020-07-22 16:06:37 +00:00
Yi Kong
60cf02515e Merge changes I90df9c04,I70bb8dc2 am: f9a78248b0 am: a7fcd17a0f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1368617

Change-Id: I2add0c4c151ccd684f0930aad0ce5819920ec127
2020-07-22 01:25:38 +00:00
Yi Kong
f9a78248b0 Merge changes I90df9c04,I70bb8dc2
* changes:
  [pgo] Allow profile gather and use flags to coexist for sampling PGO
  [pgo] Sampling PGO does not require benchmark property
2020-07-22 00:46:42 +00:00
Christopher Parsons
39e1f73131 Merge "Install data_libs using relative_install_path property" am: fef9d4b601 am: 4a016f49a9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1359742

Change-Id: I29f194fa1649a4f36f81f62d0c47c595e07994f5
2020-07-21 18:11:31 +00:00
Yi Kong
a575ff38a8 [pgo] Allow profile gather and use flags to coexist for sampling PGO
Bug: 79161490
Test: presubmit
Change-Id: I90df9c04dbe2a423c06e9a966fe9bcaed0a84a65
2020-07-22 02:01:49 +08:00
Yi Kong
84803c50a6 [pgo] Sampling PGO does not require benchmark property
Test: build with Sampling PGO
Bug: 79161490
Change-Id: I70bb8dc2e4492d6a3713ca16fcb3f1216615f8ac
2020-07-22 01:36:20 +08:00
Christopher Parsons
fef9d4b601 Merge "Install data_libs using relative_install_path property" 2020-07-21 17:26:57 +00:00
Chris Parsons
216e10a0f6 Install data_libs using relative_install_path property
Test: Added to data_libs tests
Test: Manually verified with bionic-unit-tests
Test: Treehugger
Change-Id: I28a8e08e3409f1e7c7bb72f4351310b57f35f513
2020-07-20 13:59:24 -04:00
Treehugger Robot
ebb60eca90 Merge "Add compile_multilib properties to all native prebuilts (reland)." am: 5df3439377 am: 5ae0c786e0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1363559

Change-Id: I45ecd2494556cd015eeb656c7a83d18b4922b42a
2020-07-20 15:38:48 +00:00
Treehugger Robot
5df3439377 Merge "Add compile_multilib properties to all native prebuilts (reland)." 2020-07-20 15:19:33 +00:00
Kiyoung Kim
b0aa8515b9 Deprecate VNDK-Lite
Android S would not support upgrade from O-MR1 devices, so VNDK Lite
configuration is no more valid. This change removes all VNDK-lite
variables from soong.

Bug: 158719241
Test: m -j passed
Change-Id: I54093fd4ee37ceddfc33a0b216b7069372040a0c
Merged-In: I54093fd4ee37ceddfc33a0b216b7069372040a0c
2020-07-20 05:46:11 +00:00
Dan Willemsen
2019658b86 Support per-module MakeVars
This allows setting per-module make variables earlier in the build,
particularly for prebuilt_build_tool users like LEX/M4/BISON. I moved
filegroup over because it's a simpler common interface, but it doesn't
strictly need it.

With this, the last user of the hardcoded cc.m4Cmd variable is gone.

Test: Inspect out/soong/make_vars-*.mk, out/soong/late-*.mk
Test: treehugger
Change-Id: I195b688131feac0c100c338a0749368aa5d50f4f
2020-07-17 20:07:33 -07:00
Dan Willemsen
d2e291ae5c Switch cc's use of bison and flex to prebuilt_build_tool
Test: treehugger
Change-Id: I6150f0f39151e8073d5d59fe189f614140fed57b
2020-07-17 20:07:16 -07:00
Dan Willemsen
453b4e1235 Merge "Add support for macOS 11 SDK" am: 59415ca60d am: 92601afd91
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1360927

Change-Id: I0eb2c3eb8638f02e14757e0f3079043400cf4664
2020-07-17 22:12:35 +00:00