Bug: b/256212479
Test: Prior to thi CL bp2build.symlink_forest event was missing in bp2build_metrics.pb after a clean mixed build
Change-Id: I53bfc4114a383c0d1f9c4c7945e7d4c69bc50b0c
This makes symlink forest creation ca. 2x faster again, taking 2-3
seconds instead of 5.
Who would have thought that os.RemoveAll() is slow.
Test: Presubmits.
Change-Id: I91e41319c972dbf1113cf723e383c785433c18b9
This lets us simplify more of our build configuration for stuff like
libm and libz.
Test: treehugger
Change-Id: I823c7df8117f068aeeb7067e8e197863b0fb517f
Allow single-bit-bitfield-constant-conversion warnings to pass
with r475365.
Bug: 253033919
Test: run test_compiler.py
Change-Id: Icc1f1c6c013418f1e5bb839ef70ebe8498b9cedc
These are needed to add staging-mode to some throttled builds. See go/roboleaf-launch-tests for details.
Test: m nothing
Test: build/soong/build_test.bash --bazel-mode-staging
Change-Id: I456ef80fb9c50579a28fba3dbd184d4e4653dde7
This makes it take ~5 seconds on AOSP instead of ~10. Frankly, the
speedup is somewhat disappointing but at least the code is not
complicated.
Test: Presubmits.
Change-Id: Icf94d7ca8bd80c458d014f4cf4cc1be7138deaa6
This commit removes "-advice-only from" the command of cross-version ABI
diff. The ABI changes that are incompatible with the previous version
are propagated as build errors. The developers need to follow the
error message to resolve the ABI difference.
Test: make
Bug: 244520027
Change-Id: Ic6e7757d2b35b619afcc8f50c892d1cfe989c800
This helps with incrementality a lot: the symlink forest must depend on
almost every directory in the source tree so that if a new file is added
or removed from *anywhere*, it is regenerated.
Previously, we couldn't do this without invoking bp2build, which is
quite wasteful because bp2build takes way more time than the symlink
forest creation, even though we do the latter in a very suboptimal way
at the moment.
This means that if a source file is added or removed (which does not
affect globs), we don't pay the cost of bp2build anymore.
Also refactored symlink_forest.go on the side. Too much state was being
passed around in arguments.
This change reimplements aosp/2263423 ; the semantics of not touching an
output file is the exact same as order-only inputs and the latter is a
bit fewer lines of code.
Test: Presubmits.
Change-Id: I565c580df8a01bacf175d56747c3f50743d4a4d4
This is to prepare for an imminent launch of bazel prod mode to all
users.
Note that this means a temporary test regression for bazel-built adbd, as
we have CI builds in place to verify adbd prod mode, and now we will
have no e2e coverage of mixed builds with adbd allowlisted. Still, this
test regression should hopefully be shortlived, as we begin launching
bazel-built build chunks as part of feature rollout in the coming weeks.
Test: Treehugger
Change-Id: I3c34ce91ac3454d1f71340a0fa03951f2e69f203
glinux seems to have changed, and libsegfault.so isn't
available (or at least at that location) anymore.
Test: Presubmits
Change-Id: Ic94621a2980200f24bf501e543fa6e72b0c71951
bp2build (i.e. bootstrap.ninja#bp2build_workspace_marker) generate $OUT/soong/bp2build/**/BUILD.bazel files
Having them as a dependency would thus make bp2build_workspace_marker stale upon incremental builds (because we don't re-touch the marker file if it already exists)
See Also: https://android-review.googlesource.com/c/platform/build/soong/+/2263423
Bug: b/253450880
Test: NINJA_ARGS='-d explain' m --bazel-mode adbd
repeat and see if bp2build is rerun
prior to this CL, one would see the input /usr/local/google/home/usta/aosp/out/soong/bp2build/build/make/tools/BUILD.bazel trigger bp2build over and over again
Change-Id: I904cd333a5d6ef506fc4019eda7623ef96a1daa3
- the generating rule has `restat=true`, so its output need not have a newer timestamp to prevent it from rerunning on subsequent ninja invocations
- its dependents (so far only bootstrap.ninja's "build build.ninja") already have proper dependencies in the depfile, namely
1. Android.bp.list,
2. entries in Android.bp.list,
3. bazel.list and
4. entries in bazel.list
This change prevents symlink related changes from spuriously retriggering build.ninja
Change-Id: I93f1fea7054dfbfc7c13ece34d2d1f07a81bbe07
Test: manually verifying bazel analysis is triggered only under the right set of CUJs using build/bazel/ci/incremental_build.py
Bug: b/239044236
This is okay because Blueprint already adds the module files to the
.d file of its output, so until now, they were duplicated.
Test: presubmits
Change-Id: I1bb75c5124aadd1703f3d150948dd7540ba772be
Host tools and native-bridge targets should be built on top of original
module rather than stubs. This change updates DepsMutator not to replace
to API surface stubs if target is not Android or target is
native-bridge.
Bug: N/A
Test: CF vendor build succeeded
Change-Id: I97eb98d9e63dcf15632468aa32211a14d48986a0
Bug: b/255309129
Test: `lunch aosp_x86-userdebug` and `export NINJA_ARGS="-d explain"`
Then do the following:
1) rm -rf out && m bp2build
2) touch bionic/libc && m bp2build
3) ALLOW_MISSING_DEPENDENCIES=true m bp2build
After each step above observe the following two
a)`stat out/soong/soong.environment.used.bp2build | grep Modify`
b)`stat out/soong/bp2build_workspace_marker | grep Modify`
Verified:
step 2 changes only (b) - prior to this CL, it'd change (a) as well
step 3 still changes both (as expected)
Change-Id: I98a94878a14e19043f448b0904fc67d5d1dc9733