Commit graph

7924 commits

Author SHA1 Message Date
Florian Mayer
1866bbe0d2 Increase BB to explore for reachability analysis
We pass mcpu=cortex-a55 for our build, which increases BB to the point
where the LLVM default of 32 is not enough.

I ran a fullmte build and did not see any slowdown.

Bug: 229654778
Change-Id: Ifbd1e5427101b2f2f39c067ba3ea4d5cb4a3ba0d
2023-03-14 23:45:39 +00:00
Iván Budnik
ff8c95b610 Merge "Revert "Export non-apex variants of modules to make"" 2023-03-10 16:30:32 +00:00
Iván Budnik
295da16b95 Revert "Export non-apex variants of modules to make"
Revert submission 2462194-androidmk_for_apex_dependencies

Reason for revert: DroidMonitor-triggered revert due to breakage https://android-build.googleplex.com/builds/quarterdeck?branch=aosp-master&target=full-eng&lkgb=9723453&lkbb=9724944&fkbb=9723508, bug b/272663333.

Reverted changes: /q/submissionid:2462194-androidmk_for_apex_dependencies

Bug: 272663333
Change-Id: I847fa910a8d54de19954f56fe92a80a9bcd0ee18
2023-03-10 16:11:26 +00:00
Cole Faust
f42c21d5f8 Merge "Export non-apex variants of modules to make" 2023-03-10 06:36:03 +00:00
Cole Faust
ad222f271a Export non-apex variants of modules to make
Currently, non-apex variants of modules that are in apexes are not
exported to make unless they're apex_available to the platform. This
means that you can't `m` those modules directly.

However, there is a workaround in the apex androidmk implementation that
emits make rules for the removed modules, but just redirects them to
build the apex itself. We want to remove that, but one of the problems
with doing so is that you can no longer `m` many modules afterwards.

To fix that, unhide the apex's dependencies from make. To ensure they're
not installed, call SkipInstall() on them, and update SkipInstall() to
be more strict by setting `LOCAL_UNINSTALLABLE_MODULE := true`.

Bug: 254205429
Test: Presubmits
Change-Id: Ib094feb2c437ad50d8319c58caa997759e7ce32f
2023-03-09 11:20:10 -08:00
Spandan Das
d14a70d7ed Merge changes Ib004c2c3,I6b63d9d0
* changes:
  Create aliases for stubs in build/bazel/api_surfaces
  Add a method in bp2build to create aliases in another directory
2023-03-09 18:14:13 +00:00
Zijun Zhao
add695f784 Merge "Revert "Revert "Enable -Wformat-insufficient-args globally""" 2023-03-09 07:57:15 +00:00
Zijun Zhao
d156908820 Revert "Revert "Enable -Wformat-insufficient-args globally""
This reverts commit fa6b6843a7.

Reason for revert: Bug fix: https://googleplex-android-review.git.corp.google.com/c/platform/vendor/google/whitechapel/audio/+/21912759

Change-Id: I1c95f8d813171b500fa48c809bcffb0af7179f9a
2023-03-08 23:48:45 +00:00
Spandan Das
9e93d3d6e1 Create aliases for stubs in build/bazel/api_surfaces
- Create the alias under the module-libapi directory. This is the
  api_surface that cc_stubs_suite maps to.
- Create the alias only for "current" (atleast for now)
- Create one alias for the stub shared lib, and another for its headers

Test: b build @api_surfaces//... (with aosp/2475091)
Change-Id: Ib004c2c34256f971e74d75317fa5fbbe7273720e
2023-03-08 21:40:41 +00:00
Cole Faust
912bc8862e Use product variables from the overridden apex
override_apex's bp2build converter had a bug where it was looking at
the product variables for the override_apex module itself instead of
for the base module it is overriding.

Fixes: 271424349
Test: go test
Change-Id: If1e2653d3751fa908faf0ab97dfa2e943ebe98ec
2023-03-08 12:29:50 -08:00
Ian Kasprzak
fa6b6843a7 Revert "Enable -Wformat-insufficient-args globally"
This reverts commit bb55424e55.

Reason for revert: b/272272172 - Breaking multiple builds on git_tm-qpr-dev-plus-aosp

Testing: https://android-build.googleplex.com/builds/abtd/run/L83100000959000587


Change-Id: I854e24735689b5a3b8373d3bc947d184338eedde
2023-03-08 16:49:33 +00:00
zijunzhao
bb55424e55 Enable -Wformat-insufficient-args globally
Bug: b/191699019
Test: make checkbuild
Change-Id: Ie60d626345b9a448c3d0939faba9b6250ab34f94
2023-03-08 05:18:10 +00:00
Yu Liu
6fb6b2440a Merge "Remove the NO_EXPORTING handling of libprofile-clang-extras." 2023-03-08 01:57:47 +00:00
Evgenii Stepanov
dd2e32d859 Merge "Introduce armv9-a arch variant." 2023-03-07 22:58:11 +00:00
Evgenii Stepanov
80d74920fd Introduce armv9-a arch variant.
Armv9 with mandatory PAC and BTI extensions.
Stack protector is disabled as it is irrelevant with PAC.

Bug: 263283855
Test: NFC
Change-Id: I2f298f21dade12824597e0a6920772a2bfc63afb
2023-03-07 11:18:52 -08:00
Treehugger Robot
88e949945d Merge "Revert "Produce _alwayslink sibling targets through bp2build"" 2023-03-07 07:33:16 +00:00
Wilson Sung
68e126ee62 Revert "Produce _alwayslink sibling targets through bp2build"
Revert submission 2467901-b/267214124

Reason for revert: compile error

Reverted changes: /q/submissionid:2467901-b/267214124

Change-Id: I2235fd1457fda60b4613d5512f7fb20b7044a2db
Fix: 271943047
2023-03-07 04:16:53 +00:00
Wei Li
598f92d704 Export Soong module type to LOCAL_SOONG_MODULE_TYPE to Make for SBOM generation.
Bug: 266726655
Test: CI

Change-Id: If5b1a77930a591b6061ca2749c9c5ad29b4491fb
2023-03-06 22:51:03 +00:00
Yu Liu
9cc34a7142 Remove the NO_EXPORTING handling of libprofile-clang-extras.
This is no longer necessary after we reduce the exported static libs in
roboleaf.

Bug: None
Test: b build adbd with coverage enabled.
Change-Id: Ia049138c4cdd536670371b4fc9a54fca40d16d20
2023-03-06 11:13:03 -08:00
Treehugger Robot
80ebd72995 Merge "soong: Add Cortex-A32 definitions" 2023-03-06 17:26:20 +00:00
Alex Márquez Pérez Muñíz Díaz Puras Thaureaux
0eee856e69 Merge "Produce _alwayslink sibling targets through bp2build" 2023-03-06 14:43:28 +00:00
Kiyoung Kim
8972e4d6bb Merge "Implement API surface import with APEX stub" 2023-03-06 00:40:13 +00:00
Jesus Sanchez-Palencia
de7c7847e7 soong: Add Cortex-A32 definitions
Add definitions for the Cortex-A32 CPU. This is an aarch32 only ARMv8-A
core. See more here https://developer.arm.com/Processors/Cortex-A32 .

Test: added new minidroid target using this CPU variant and built
Change-Id: Id2351a43b9c6cb9785ef469b8c13fadd8b6324b8
Signed-off-by: Mark Slevinsky <markslevinsky@google.com>
Signed-off-by: Jesus Sanchez-Palencia <jesussanp@google.com>
2023-03-03 14:14:03 -08:00
Alex Márquez Pérez Muñíz Díaz Puras Thaureaux
011b7cf063 Produce _alwayslink sibling targets through bp2build
Add Alwayslink to bazelPrebuiltLibraryStaticAttributes
Also adjust the corresponding tests to espect these new targets.

Test: m libc
Test: b build --config=android //prebuilts/clang/host/linux-x86:libunwind-exported_alwayslink
Test: bp2build.sh
Bug: 267214124
Change-Id: I4d996aef55321f1827947f00b0eaa52d0a14413e
2023-03-03 20:12:20 +00:00
Trevor Radcliffe
56b1a2b575 LTO Bp2build
Bug: 261733821
Test: Unit Tests
Change-Id: I8c3721d35c464e296012145b2e95a7f0866aac37
2023-03-02 17:45:01 +00:00
Yi Kong
cec8b2c0b7 Merge "Revert "Update clang version to clang-r487747"" 2023-03-02 09:25:42 +00:00
Treehugger Robot
8c41eca698 Merge "Remove OWNERS access for non-build team people to core build system" 2023-03-01 19:45:38 +00:00
Helen Qin
9ede280375 Revert "Update clang version to clang-r487747"
Revert submission 2446165-update-clang-r487747

Reason for revert: DroidMonitor-triggered revert due to breakage bug b/271252582 and b/271243811

Reverted changes: /q/submissionid:2446165-update-clang-r487747

Bug: 271252582
Bug: 271243811
Change-Id: I3b5c44982d268b5c6c3db39e7af4d7aa7c6dfbf7
2023-03-01 19:31:36 +00:00
Yi Kong
29ff4182f5 Merge "Update clang version to clang-r487747" 2023-03-01 05:02:15 +00:00
Joe Onorato
442b6fc701 Remove OWNERS access for non-build team people to core build system
Test: treehugger
Change-Id: I0c318ddd7d78110327bbd849ed9aa3973c86de5d
2023-02-28 19:29:47 -08:00
Cole Faust
18994c73f1 Replace SortedStringKeys with SortedKeys
Now that we have generics.

Bug: 193460475
Test: presubmits
Change-Id: I1594fd8feb505175d5c09c03ef397e5ffd5b09cb
2023-02-28 16:51:32 -08:00
Omar Eissa
fabd0dd8d3 Revert "Enable -Wformat-insufficient-args globally"
This reverts commit 49f09a3694.

Reason for revert: b/271045282

Change-Id: Ice56137c5567a38d15cc39f80497ce74bc18650f
2023-02-28 11:08:57 +00:00
zijunzhao
49f09a3694 Enable -Wformat-insufficient-args globally
Bug: b/191699019
Test: m
Change-Id: Ib71a422a7a1621c0994ea07a90fa9ab914fcc6fd
2023-02-27 22:55:01 +00:00
Kiyoung Kim
76b06f3973 Implement API surface import with APEX stub
Implement APEX stub of API surface so any stub can be replaced with API
surface when APEX stub interface is required.

Unlike other stub interface, APEX stub can be decided if it should be
used after APEX postdeps mutator analyzes which modules should be
included in which APEX. To cover this, APEX stub is being added to the
dependency if the dependency should not be covered with LLNDK or NDK
stub, and APEX stub exists. From depsToPaths, if dependency to both
original module and API library exists, then it choose one of the
dependency and ignore the other.

To cover this logic, a new property is added to the api_surface :
apex_libs. This is introduced as it is difficult to
gather all api library with apex stub before DepsMutator.

Bug: 264963986
Test: cf_x86_64_phone_vendor build succeeded
Change-Id: I9f0b1f70968e32eba94d3e0d7bb1f4bb29ff2438
2023-02-27 12:57:30 +09:00
Jooyung Han
8ecedd4dfc Merge "Prevent sdk variants from install" 2023-02-27 00:41:34 +00:00
Yi Kong
836690b593 Update clang version to clang-r487747
Test: presubmit
Bug: 264965700
Change-Id: I2db879f4dcc77b606c788b3e3890ed2a3faa6594
2023-02-23 20:49:59 +00:00
Yu Liu
995a3a192f Merge "Only apply apex transition to DCLA libs for now." 2023-02-23 02:16:19 +00:00
Yu Liu
89ce6bd127 Merge "bp2build of libraries with stubs should handle non-implementation deps" 2023-02-22 23:35:04 +00:00
Yu Liu
bfb2362cde Only apply apex transition to DCLA libs for now.
Bug: 270339610
Test: mixed_droid.sh
Change-Id: I6a8b7fdefeb504a25256e92647de9b487d5b65a3
2023-02-22 10:43:46 -08:00
Iavor-Valentin Iftime
a1e3a55810 Merge "Revert "Revert "Revert "Enable -Wformat-insufficient-args globally"""" 2023-02-22 10:22:40 +00:00
Iavor-Valentin Iftime
3251d4a6f0 Revert "Revert "Revert "Enable -Wformat-insufficient-args globally"""
This reverts commit c50ae9c6e2.

Reason for revert: b/270300283

Change-Id: I7da15937b200e707847bcf1403d4a7ac55c0822c
2023-02-22 10:18:51 +00:00
Treehugger Robot
ee8daaa689 Merge "Revert "Revert "Enable -Wformat-insufficient-args globally""" 2023-02-22 09:25:19 +00:00
Jooyung Han
54f780505d Prevent sdk variants from install
Platform variants should be available even when unbundled_build so that
unbundled build of com.android.virt apex can correctly have microdroid
image with system variants.

Bug: 268582372
Test: m (soong test)
Test: banchan com.android.virt aosp_arm64
      UNBUNDLED_BUILD_SDKS_FROM_SOURCE=true m apps_only dist
      (microdroid should have the same contents)
Change-Id: I682e4f1f477f3024f7719dfaa67006ef335e0640
2023-02-22 13:45:49 +09:00
Zijun Zhao
c50ae9c6e2 Revert "Revert "Enable -Wformat-insufficient-args globally""
This reverts commit cc1d984d49.

Reason for revert: Fixed 
https://googleplex-android-review.git.corp.google.com/21522363

https://source.corp.google.com/h/googleplex-android/platform/superproject/+/tm-qpr-dev-plus-aosp:vendor/google/whitechapel/audio/hal/audio_hal/ext_module/amcs_ext/amcs_ext.c;l=266;bpv=1

Change-Id: I79ee06b720f1299ab02cb129baabb3c025c31483
2023-02-22 00:38:28 +00:00
Yu Liu
10174ff208 bp2build of libraries with stubs should handle non-implementation deps
Bug: 266724299
Test: Unit test and manual tests
Change-Id: I7d7641676fbf3d3fae413b27d329a4b05b1cd3bf
2023-02-21 12:07:07 -08:00
Yu Liu
e43124023c Support DCLA
Bug: 240424572
Test: Manual tests:
1. m --dev-mode-staging com.android.adbd com.android.media.swcodec.
2. verify the DCLA libs from the two apexes have the same size and
   sha1sum, and also match the libs in bazel-out.
3. empty the DCLA libs list in allowlist.go and repeat step 1
4. repeat step 2 and verify the opposite result
5. build git_master: mainline_modules_bundles-userdebug in ABTD
   with the cl, then follow go/build-sideload-dcla-locally to
   download the adbd and swcodec aab files, run the DCLA trimming
   workflow locally, and verify the symlinks in the two trimmed
   apexes are identical and also match the lib path in the DCLA
   apex that was created by the workflow.

Change-Id: Ib2f8a29126a54829c0e10eba17b256a79930fd70
2023-02-21 10:12:47 -08:00
Alex Márquez Pérez Muñíz Díaz Puras Thaureaux
01ec55ec92 Express no{,_lib}crt via features vs attrs
Given that we can map them directly to disabling the
corresponding Bazel features: `-{link_,use_lib}crt`

Test: Existing (adapted) Unit Tests
Test: bp2build.sh
Change-Id: Ib502f6fb929ace8e86a1001e3cc21f399317500c
2023-02-17 19:24:42 +00:00
Andrea Zilio
cc1d984d49 Revert "Enable -Wformat-insufficient-args globally"
This reverts commit af8b950357.

Reason for revert: Broke the build, see b/269687118

Change-Id: I6f7fac0e24c710bd00af77e4d96c845eefe0a9ce
2023-02-17 11:51:10 +00:00
zijunzhao
af8b950357 Enable -Wformat-insufficient-args globally
Bug: b/191699019
Test: m
Change-Id: I6349308d1f8b13e5c5d75b154e8c9b53d9eec4bf
2023-02-16 17:52:22 +00:00
Yi Kong
32a15c4269 Merge "Remove bug links for noOverrideExternalGlobalCflags" 2023-02-16 11:46:16 +00:00