We've had some incrementality issues with the symlink forest since
aosp/2673616, clear old symlink forests to get rid of the bad symlinks.
Bug: 300129912
Test: Presubmit
Change-Id: Ic23c980b68ebcc8b8788d56e53435f0a89d82b28
Previously, partners were required to add an
android_certificate_directory filegroup in their certificate
directories, and allowlist that BUILD file. Now, we generate the
filegroup automatically.
We're using a different name, generated_android_certificate_directory,
to avoid conflicts with already-checked-in filegroups.
Bug: 285777389
Test: b test //build/bazel/rules/apex/...
Change-Id: Ib1bde487acd79d58368faf0aad02ded0bcdaceb4
java_library doesn't accept deps when there are no srcs because
no compilation happens, but it accepts exports.
The deps from the module are not necessary for compiling the protos,
in which case they are unnecessary as deps on the java_library as well
since they are not be propagated to any dependencies.
So we can put the deps to exports and drop deps here.
Test: CI and added unit test
Bug: 285952385
Change-Id: Ie54a4ac0db592fb96fede64f0e67df309dca9c1d
Also add script to remove the Bazel output base.
This will assist with supporting movable checkouts alongside
mixed builds.
Bug: 259191764
Test: m && (move topic and prepare_moved_top.sh) && m
Test: m && prepare_moved_top.sh && m
Test: build/soong/tests/relative_symlinks_test.sh
Change-Id: I0f53da8d99f752fad496cf3ac61b01f001b7296d
To maintain good backwards compatibility with the legacy partition
building behavior, allow actions to read
BUILD_BROKEN_INCORRECT_PARTITION_IMAGES so that we don't have to rerun
analysis.
Bug: 205632228
Test: Presubmits
Change-Id: I2b55c0143cbdaf010e6b5fd0c3d51d6930a94eff
Previously we would convert to java_resources when there were no
resources and get an error.
Test: b build //external/libphonenumber/... --config=android
Change-Id: I86f30b993a3ffdb20000f6a4c5261e2c4c74263c
Soong adds "--no-ndk" to cc stubs for apexes if the library is not an
NDK library. In order to port this logic, emit the list to a .bzl file.
We cannot use the exportedVars.Export* soong_injection api for this
since we need to visit all modules to get this list.
Test: m nothing
Bug: 299501496
Change-Id: If8487db85e08b32b9b40aef3371d9f3f7d5a77e0
src == name causes circular dependency errors, instead mark these as
unconverted and don't create modules for them.
Test: m bp2build and verify boringssl_self_test.zygote64.rc unconverted
Change-Id: I5d5fdd7e14830cd685816064cd0377998d07293c
For a dependency edge A --> B (stublib), Soong will link A's platform
variant against impl of B's platform variant if either of these are true
1. A and B have same apex_available
2. B has bootstrap: true
3. B is only available to platform
(3) was missing from bp2build. This CL adds that.
To implement this, we check the `apex_available` property of B.
Test: updated bp2build tests
Test: Built the internal module b/299191635 that was failing due to this
Bug: 299191635
Change-Id: Iafb173a3ab20d69b89f7949ce40c6f4096396f24
This was likely missed in aosp/2630914 because this file was never added
in testSrcs of soong-bp2build
Test: go test ./bp2build
Bug: 284029211
Change-Id: I715f6ca17ccc2fbee1b6dcb43fd5a78d1b7380b7
For explicit values of compile_multilib (e.g. 32 or 64), add an
incompatibilty constraint for the arches that do not have the correct
bitness.
Test: go test ./bp2build
Bug: 299135307
Change-Id: I4cd997de6804a5c6d89086d740f773936db1cab9
This feature is obsolete.
This makes a large number of codepaths "dead code" (such as
module-specific implementations of ApiBp2build functionality). These
will be deleted in a followup CL.
Bug: 284029211
Test: Presubmits
Change-Id: Ib53b99f1fe8c24380d219caf44e9bb3b96724fa0
A single proto providing directory can be used by multiple soong modules. Some of these
can be
1. Host specific
2. Device specific
3. Both host and device
Since the generated proto_library can have 1:many mapping, it should
have an empty target_compatible_with. Compatiblity will be enforced at
the top-level {cc|java|python}_proto_library.
(This is a followup to aosp/2727054 which did not handle this correctly)
Test: Added a unit test
Change-Id: I09b3def70e3d043fd8ba0d1eb4ffff1910f097d1
When sdk_version is unset, the build with fail with Bazel because
private APIs are do not build with Bazel at this time.
This instead prevents migrating the relevant target to Bazel in bp2build
Test: go tests
Change-Id: I31dabcf143de7933706d1b734ef21467a01b65e9
The fixes are
- Dedupe the dir list. Since we partition the proto srcs per pacakge and
then iterate the map, a single include directory was being listed
multiple times
- Drop target_compatible_with from these proto_library targets. The
compatibility will be enforced at the top-level <lang>_proto_library.
Test: Added a unit test
Change-Id: Ia18c0f8c495585010fd4e372092afe80c5d8290c
Since this is a one-off just for building libprotobuf that will be removed when we handle cargo output more generically (b/297364081), I didn't write a unit test for this CL.
Test: b build //external/rust/crates/protobuf:libprotobuf
Bug: 295925256
Change-Id: I00cf44d54be27a09c184a96c13b250a2e54e2d10
The prebuilt_ prefix was removed before writing converted modules, which
causes false positives when a prebuilt and from source module exist with
the same name but only one has been converted
Test: b run //build/bazel/scripts/bp2build_progress:bp2build_progress \
-- report -m core-lambda-stubs-for-system-modules
Change-Id: Id00099780fb6af9fffcf745b509116a66bac8756