Commit graph

64108 commits

Author SHA1 Message Date
Nicolas Geoffray
addd60c430 Merge "Revert^2 "Generate a boot image extension for mainline BCP..." 2023-03-16 16:07:45 +00:00
Treehugger Robot
feeee3ad26 Merge "make tidy attribute tri-state" 2023-03-16 15:42:21 +00:00
Sam Delmerico
5f90649036 remove stub dependency on source_library
Since the source_library attribute of _cc_stub_library_shared was a
label attribute, the source library was added as a dependency of the
stub which doesn't always make sense. E.g. it caused validation actions
for the source library to run even when we weren't building the source
library.

This change converts the label attriubte to a string attribute so that
we don't add the dependency.

Bug: 263390551
Change-Id: I19c62d1e14847dff68ab37156452addaa119eaf9
2023-03-16 10:01:22 -04:00
Jeongik Cha
0cf44d5e8d Add --ninja_weight_source option
It has 3 options for now.
* ninja_log: uses ninja log file for data source
* evenly_distributed: pass empty list for ninja to consider every work as the same
* not_used: do not use critical path logic in ninja

In addition, I added the option in the metrics to track

Bug: 271527305
Test: m --ninja_weight_source=ninja_log|empty|not_used
Change-Id: Ib4c812c20606a34b17d3f0edb71057b477c4f90e
2023-03-16 19:52:27 +09:00
Jeongik Cha
767ce714bb Add time unit for CriticalPathInfo's fields' name
Bug: 271526845
Test: check metrics
Change-Id: Ie7e133033371906b29caad16d0b6bcd238b9f8db
2023-03-16 18:29:55 +09:00
Jiakai Zhang
b879620ca8 Revert^2 "Generate a boot image extension for mainline BCP...
Revert submission 2465993-boot-image-mainline-revert

Reason for revert: Relanding the changes

Reverted changes: /q/submissionid:2465993-boot-image-mainline-revert

Change-Id: Ie611cf3a1ff4be7a7beab164f69b4186c474be5c
2023-03-16 08:46:29 +00:00
Prashanth Swaminathan
0344c024fd Enable VNDK when version matches platform VNDK
When evaluating whether to build the VNDK for the multi-target
configurations, we construct the API level based on the VNDK
version. When the VNDK version is 'current', we replace the
version name with the platform SDK version e.g. 'UpsideDownCake'.

For architectures that currently have a MinApiArch of FutureApiLevel
(i.e. 'current'), comparing 'UpsideDownCake' with 'current' will
assume 'current' is at a higher API level and skip building the
VNDK.

Before perofrming the API level comparison, we check that the VNDK
version does not match the platform VNDK version. If true, it is
necessary to disable the VNDK when it does not meet the minimum API
level for the architecture. If false, we skip this check and allow
the VNDK to be enabled, as this implies we are targeting the 'current'
VNDK version and should include the target platform VNDK.

Test: m (soong test) & boot
Change-Id: Iacc33d2858fef670ddfdff5bbde9d32b084979c9
2023-03-15 23:28:45 -07:00
Jooyung Han
e606759ddf Make filesystem aware of coverage
filesystem should have coverage variants with coverage-enabled build.
Otherwise, it would fail to collect dependencies.

Bug: 273238141
Test: m nothing (soong tests)
Test: compare the artifacts
 $ SKIP_ABI_CHECKS=true SOONG_COLLECT_JAVA_DEPS=true EMMA_INSTRUMENT=true\
   EMMA_INSTRUMENT_FRAMEWORK=true CLANG_COVERAGE=true\
   NATIVE_COVERAGE_PATHS='*' m microdroid
 $ m microdroid
Change-Id: I792458ace00a63b4b5213898fd3209351a6e00be
2023-03-16 13:11:17 +09:00
Dan Willemsen
aa2b7cc21d Rename mk2rbc/cmd to make go install work properly
The standard go tooling assumes that a package's binary name should be
the name of the containing folder. Before this change, `go install` or
`go build` (without `-o`) names this binary `cmd`.

Test: treehugger
Change-Id: I45a4e97f4a0d59744d644e30636250ceefe3bd1c
2023-03-15 22:51:01 -04:00
Treehugger Robot
da4a78bf40 Merge "Add --multitree-build flag" 2023-03-16 02:34:22 +00:00
Justin Yun
24b246a7a8 Fix the make name of rust snapshots
Rust snapshot must have proper suffix for androidmk to avoid conflict
with the existing modules.

Bug: 230780263
Bug: 235895567
Test: m nothing
Change-Id: I35794196553621cd722c067d7965b2a61aa351bd
2023-03-16 11:05:41 +09:00
Treehugger Robot
eabe937355 Merge "Add external/escapevelocity to allowlist" 2023-03-15 23:48:26 +00:00
LaMont Jones
52a7243387 Add --multitree-build flag
Add a flag that enables logic specific to multitree-build builds.

Bug: b/266730267
Test: treehugger, manual
Change-Id: Ia6f392525faa9d66bb6e0692b2a2e9c3b8493b0d
2023-03-15 23:08:34 +00:00
Kevin Dagostino
24de5f2485 Merge "Cache GoogleProdCredsExist() to save ~800ms during builds." 2023-03-15 21:44:26 +00:00
Usta Shrestha
d66f2ce93d Add external/escapevelocity to allowlist
Test: build/bazel/ci/bp2build.sh
Bug: 273739117
Change-Id: Iee11cc6029d1bce5a426a4467dd661630c8c3e9a
2023-03-15 15:04:59 -04:00
Charisee
39f2d443ea rustc-1.68.0 Build 9751466
Bug: 270756468
Test: m rust
Change-Id: Ifa04d7fbbdc8ced9956aa50372df80ed6f481c02
2023-03-15 18:42:31 +00:00
Wei Li
73032c8fa3 Revert "Revert "Revert "Revert "Add integration test for testing generat...""
This reverts commit 1e75eccb18.

Reason for revert: The SBOM generation change has been submitted in aosp/2485540, so its integration test in this change should be ok to submit now.

Change-Id: Idb8c84a871b2a5633bed998eb7483fc91d30e97a
2023-03-15 18:31:38 +00:00
Sam Delmerico
63f0c93b09 make tidy attribute tri-state
Bazel boolean attributes can only support true or false states, but the
clang-tidy logic changes for modules which don't set a specific value.
Therefore, the tidy attribute should really be a tri-state of "true",
"false", or "" (unset).

Test: b test //build/bazel/rules/...
Bug: 268681923
Change-Id: I85fbaa612d175f475757db806cea6c018901fe3e
2023-03-15 10:10:43 -04:00
Treehugger Robot
cd7db25738 Merge changes I7ec5a9f7,I76807f9b
* changes:
  Add docstrings for CriticalPathInfo
  Add long running jobs info
2023-03-15 07:26:40 +00:00
Jeongik Cha
cf833776a4 Add docstrings for CriticalPathInfo
Bug: 271526845
Test: n/a
Change-Id: I7ec5a9f7b39fd7441f1aac6556a77046a8210ae8
2023-03-15 12:54:14 +09:00
Jeongik Cha
4199d4796c Add long running jobs info
For the data to prioritize long running tasks in ninja, I added the
information about that.

Bug: 271526845
Test: build and check metrics
Change-Id: I76807f9b0d6a50d940b5f35dd6a9ef3cf693eec5
2023-03-15 12:46:58 +09:00
Jeongik Cha
58fa5a3f36 Merge "Add critical path infomation into metrics" 2023-03-15 03:40:11 +00:00
Treehugger Robot
79727bd236 Merge "Enable Wunqualified-std-cast-call globally" 2023-03-15 01:41:58 +00:00
Florian Mayer
b0c9dd777e Re-enable stack frame size errors
Bug: 229654778
Change-Id: Ib7d0ef98577adbd69b98cac450d3727ab1fdec81
2023-03-14 23:46:15 +00:00
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
Alex Márquez Pérez Muñíz Díaz Puras Thaureaux
b157846a68 Merge "Revert "Revert "Produce _alwayslink sibling targets through bp2b..."" 2023-03-14 23:01:47 +00:00
Treehugger Robot
2f58ad52e5 Merge "Allow "-mllvm foo" cflags" 2023-03-14 22:01:58 +00:00
Xin Li
a0ede28632 Merge "Merge Android 13 QPR2" 2023-03-14 21:40:45 +00:00
zijunzhao
96ec99a736 Enable Wunqualified-std-cast-call globally
Bug: b/239662094
Test: make checkbuild
Change-Id: Icd012c12ce13e04efa269c6898823c1178a02b74
2023-03-14 21:27:48 +00:00
Spandan Das
8b08aea32e NDK ABI diffs requires implementation
ABI diffs reqiures implementation and cannot be generated from the
imoprted <lib>.apiimport soong module

Test: go test ./cc
Change-Id: Ie1da877a5a7d8b984112b64ca7d2c3d4c8d99cb4
2023-03-14 21:07:58 +00:00
Treehugger Robot
f214f12014 Merge "Respect Clang version override env vars." 2023-03-14 20:25:58 +00:00
Alix Espino
d184706daa Merge "bp2build kotlinCFlags" 2023-03-14 18:35:15 +00:00
Treehugger Robot
261bc29678 Merge "Omit linux_bionic in mixed builds." 2023-03-14 18:07:17 +00:00
Liz Kammer
11ec91f652 Omit linux_bionic in mixed builds.
We do not have toolchains set up for linux bionic at this time.

Bug: 273425275
Test: CI
Change-Id: I72760eabeb7be28f176eaaf4c6b9954dfdca1e42
2023-03-14 10:03:38 -04:00
Alix
f848bf8225 bp2build kotlinCFlags
for java_library, java_binary, android_app & android_library

Change-Id: Ia8dec7e7d497eb41b2d8dcd8c44c3090d1d3b4bd
Bug: 271265771
Test: go test ./bp2build
2023-03-14 13:57:22 +00:00
Anton Hansson
a8c1cacaf9 Merge "Add filegroup_defaults module" 2023-03-14 12:04:13 +00:00
Jeongik Cha
28c1fe5bc8 Add critical path infomation into metrics
To improve build efficiency, the metrics for critical path and
parallelism ratio is necessary. That information has been included in
soong.log, so added it into metrics as well.

Bug: 271526845
Test: build and check if metrics pb has critical path info
Change-Id: I14e1a78c13d400b792d3b05df18604da48759ade
2023-03-14 17:59:22 +09:00
Anton Hansson
eaab87405c Merge "Add filegroup_test.go to sources" 2023-03-14 07:58:40 +00:00
Xin Li
1979b21b23 Merge Android 13 QPR2
Bug: 273316506
Merged-In: I7d8585c97ca1e9a960d9725135f99579b0ae5762
Change-Id: I154a78c6b6ad17d1a240ab71b93d9ca500181d7d
2023-03-13 23:09:04 -07:00
Kevin Han
acfaf20c25 Merge "Revert "Revert "Revert "Add integration test for testing generat..."" am: a2e8ae1771
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2485538

Change-Id: I79d24fafc48c5ae4d3d08cfb080e43daffa89388
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-13 21:28:45 +00:00
Kevin Han
a2e8ae1771 Merge "Revert "Revert "Revert "Add integration test for testing generat..."" 2023-03-13 21:03:23 +00:00
Kevin Han
1e75eccb18 Revert "Revert "Revert "Add integration test for testing generat..."
Revert submission 2481062-sbom

Reason for revert: b/273332655

Reverted changes: /q/submissionid:2481062-sbom

Change-Id: I9297f585ab426d0b5586a7a77e983e8bafb19f20
2023-03-13 20:57:32 +00:00
Matt Gilbride
d9ccbe1eb9 Merge "Disable new lint checks from Android Studio" am: 34127be4e9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2383132

Change-Id: Icc1c1475d980f88bd08481f597e6003933e5906d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-13 18:34:27 +00:00
Wei Li
5a64d35e28 Merge "Revert "Revert "Add integration test for testing generated SBOM with .im...""" am: 601fc0137e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2482056

Change-Id: I6dc7fe6e81bd9cda0fea504f81cf21389432bb8e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-13 18:33:30 +00:00
Matt Gilbride
34127be4e9 Merge "Disable new lint checks from Android Studio" 2023-03-13 18:03:46 +00:00
Wei Li
601fc0137e Merge "Revert "Revert "Add integration test for testing generated SBOM with .im...""" 2023-03-13 17:43:59 +00:00
Alix Espino
fd11e9ee5b Merge "Update load statements in java.go bp2build" am: 686df31852
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/2480297

Change-Id: I132636c4b4d96394eb844435fb7c31212bd93fae
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-03-13 16:07:00 +00:00
Anton Hansson
7d6dd8bb33 Add filegroup_defaults module
Allows specifying shared filegroup attributes in a central place.

Test: filegroup_test.go
Change-Id: I82feac37ae6998313a0004f8af58f3decf7a514e
2023-03-13 16:02:06 +00:00
Alix Espino
686df31852 Merge "Update load statements in java.go bp2build" 2023-03-13 15:27:15 +00:00
Alix
82acaf545f Update load statements in java.go bp2build
load statements will all now point to rules.bzl files and won't have to
be constantly updated.

Bug: 271612705
Test: CI
Change-Id: I663b9730f1b5b333682ea301ce4d9a505626faaa
2023-03-13 15:27:01 +00:00