Commit graph

81433 commits

Author SHA1 Message Date
Cole Faust
12c8ed4601 Add tests for "unset" select statements
See the blueprint cl for more information.

Bug: 323382414
Test: m nothing --no-skip-soong-tests
Change-Id: I3a0302f370e8e498556b219cbda70bdb0255f6ef
2024-04-04 10:41:43 -07:00
Spandan Das
e5e0fb0fe5 Merge "Use cp instead of install for ndk_headers" into main 2024-04-04 16:39:58 +00:00
Hsin-Yi Chen
576b4f1a77 Merge "Refactor header ABI checker code" into main 2024-04-04 03:27:36 +00:00
Spandan Das
1202729cb2 Use cp instead of install for ndk_headers
ndk_headers currently use ctx.Install to install headers in
out/soong/ndk/sysroot. The files are subsequently used to compile ndk
variants of cc libraries on host.

Since these headers are not actually installed on device, use android.Cp
to assemble the NDK sysroot. By itself, it should be a no-op, but
androd.Cp is more friendly with restricting the installation rules to
PRODUCT_PACKAGES.

To make it explicit that the sysroot is not a typical installation path,
this CL also modifies the type to OutputPath

Test: m
Bug: 332778109
Change-Id: I1131c3c764443cbaac525c6022cd09c47695d275
2024-04-04 01:58:21 +00:00
Inseob Kim
4caca1d797 Merge "Add libs for BuildManifest.apk generation" into main 2024-04-04 00:43:31 +00:00
Treehugger Robot
0c8ed5e58a Merge "Drop host variant of lidbexfile in >=V snapshots" into main 2024-04-03 20:31:23 +00:00
Spandan Das
cfff924ef9 Drop host variant of lidbexfile in >=V snapshots
The host variant of libdexfile and its deps were added to module sdk to
support the use case of building platform tests without art's source
code. This use case is not very relevant today, so we can drop the host
variant of these modules from the module sdk.

We still need to keep them in <= U snapshots, so this CL uses a hack to
drop these libraries only if `SOONG_SDK_SNAPSHOT_TARGET_BUILD_RELEASE`
is greater than UDC

Test: SOONG_SDK_SNAPSHOT_TARGET_BUILD_RELEASE=UpsideDownCake m
out/soong/mainline-sdks/art-module-host-exports-current.zip # verified
that libartbase is in the generated Android.bp

Test: m out/soong/mainline-sdks/art-module-host-exports-current.zip #
verified that libartbase is not in the generated Android.bp

Test: In `main`, deleted the host variants from prebuilts/module_sdk locally; enabled art prebuilts;
Test: atest --host --no-bazel-mode libunwindstack_unit_test

Bug: 329830257

Change-Id: Iab23853ef5e96661a5f5c2989add1be32fb07fbc
2024-04-03 17:19:39 +00:00
Treehugger Robot
7805edb940 Merge "Update Android.mk denylist to block frameworks/" into main 2024-04-03 17:07:43 +00:00
Jihoon Kang
32e1b930e9 Merge "Add API compatilibility flags to the exportable stubs" into main 2024-04-03 15:34:43 +00:00
Nelson Li
ad3dae8780 Update Android.mk denylist to block frameworks/
All Android.mk files under `frameworks/` have been converted to
Android.bp. Add it to the block list to avoid using any newly added
Android.mk.

Bug: 322732227
Test: CIs
Change-Id: I1980b2f94704c15d60579b21915e51e0f4a35c1e
2024-04-03 15:17:49 +00:00
Inseob Kim
1e6afedb96 Add libs for BuildManifest.apk generation
Bug: 330282551
Test: m aosp_cf_system_x86_64
Change-Id: I4f99b5638490dae4f1da22287647ef4dfd47dcaa
2024-04-03 17:24:54 +09:00
Hsin-Yi Chen
af369886e5 Refactor header ABI checker code
- Extract duplicate code into exportedIncludeDirsForAbiCheck.
- Convert libraryDecorator.sAbiOutputFile to a local variable.

Test: make
Bug: 314010764
Change-Id: I99a0352b11347ad363df5645ba8e0faf9bc9a0aa
2024-04-03 09:09:18 +08:00
Kiyoung Kim
6954bd2337 Merge "Remove PlatformVndkVersion property" into main 2024-04-03 00:48:04 +00:00
Luis Useche
ff54ac08b2 Merge "Add global C flags to compile_commands" into main 2024-04-02 23:00:37 +00:00
Treehugger Robot
eabd1ef484 Merge "Strip relative paths from android_library_import output files" into main 2024-04-02 21:01:45 +00:00
Luis Useche
342fa6b927 Add global C flags to compile_commands
This solves linter warnings in editor by adding flags to ignore errors
we don't care about. This also means that compile_commands.json is
closer to the flags we actually use for compilation.

Test: Checked generated compile_commands for new flags.

Change-Id: Id583da6eb5151a9baa9a47771f5f937c88bc43f7
2024-04-02 13:58:13 -07:00
Colin Cross
28ac2ffc80 Strip relative paths from android_library_import output files
androidx.annotation_annotation is used as a test data file, and
converting it from an android_library to an android_library_import
causes the relative path used in the test data path to change.
Clear the relative path in android_library_import the same way that
android_library and other java based modules do.

Also change the name of classes-combined.jar to the name of the
module so that the output file has the right name if there are no
static dependences that require running the merge_zips step.

Bug: 288358614
Test: TestAndroidLibraryOutputFileRel
Change-Id: I28210aa370a742d789102ff71db3685ca744878f
2024-04-02 12:21:34 -07:00
Zi Wang
ddb2ee512c Move jarjar repackage action before combine action
With this change, the jarjar repackage actions are only on
the local classes of each module instead of the combined jar
that contains the static libs. The static libs don't need
jarjar repackage action on this module level because it has
been repackaged when building itself.

This change also removes the skip_jarjar_repackage property
since it's incompatible with this change. Actually skipping
jarjar repackage on a dep may result in incomplete repackage
on the module output.

Test: CI and observing the build time of SystemUIGoogle
Bug: 328067025
Ignore-AOSP-First: Will cp to aosp
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:78ffdd47a658dec4bf79e63d11a5f0f3b94876a4)
Merged-In: I476d959af025c46d2ba6d3f48ea378a086666a33
Change-Id: I476d959af025c46d2ba6d3f48ea378a086666a33
2024-04-02 16:44:02 +00:00
Inseob Kim
f16c5a0a7d Merge "Add support to generate fsverity metadata" into main 2024-04-02 07:19:32 +00:00
Treehugger Robot
0553cf8441 Merge "Support pyhon_rule_defaults in Soong" into main 2024-04-02 02:15:57 +00:00
Kiyoung Kim
683d7316cd Merge "Remove VNDK information from Rust, etc, and sysprop tests" into main 2024-04-02 01:14:40 +00:00
Spandan Das
e8abc2389e Merge "Add a warning that Use_source_config_var is being deprecated." into main 2024-04-02 01:08:11 +00:00
Inseob Kim
5339184e32 Add support to generate fsverity metadata
By setting fsverity.inputs, android_filesystem can now generate
.fsv_meta and BuildManifest.apk. It has been done by Makefile because
Makefile is the only one knowing all installed files. But now
android_filesystem is aware of all artifacts, so we can move fsverity
metadata generation into Soong.

Bug: 330282551
Test: m aosp_cf_system_x86_64 and see output
Change-Id: Iae4dd83eaede960c263bfba537211df4ff4b36bd
2024-04-02 10:04:22 +09:00
Spandan Das
a9cf0c8f5b Add a warning that Use_source_config_var is being deprecated.
Bug: 308188211
Test: None # documentaiton change
Change-Id: I28c7d84ed25e1aa51648c3b29cf04b1309f9a498
2024-04-01 22:37:38 +00:00
Spandan Das
15a1d29233 Pin TARGET_PRODUCT to aosp_arm in integration tests
aosp/3019827 does not handle the case where integration_tests might be
run from an unlunched-terminal. In this scenario, the ninja file will be
generated at out/soong/build.ninja.

To support running integration tests with/without lunch as well for
consistency of tests across different setups (users/CI etc.), pin the
TARGET_PRODUCT to a default value (aosp_arm for now)

Test: build/soong/tests/run_integration_tests.sh without running lunch
Change-Id: I1197923867643986ed3736cfc284632aa82dca13
2024-04-01 21:37:13 +00:00
Treehugger Robot
ab1296abc8 Merge "Add android_system_image_defaults" into main 2024-04-01 18:52:35 +00:00
Cole Faust
488868ddf4 Merge "Add tests for new boolean addition behavior" into main 2024-04-01 18:01:15 +00:00
Treehugger Robot
8ca663b4aa Merge "Fixes for run_integration_tests.sh" into main 2024-04-01 17:45:56 +00:00
Jesse Melhuish
219ce55481 Merge "Allow Multilib in override_apex" into main 2024-04-01 14:01:59 +00:00
Ted Bauer
553bfd21d6 Merge "Add logging dependencies to Rust aconfig APIs" into main 2024-04-01 13:31:11 +00:00
Kiyoung Kim
fa13ff194c Remove PlatformVndkVersion property
Platform VNDK version is no longer available based on VNDK deprecation.
Remove all code using Platform VNDK version.

Bug: 330100430
Test: AOSP CF build succeeded
Change-Id: I7d0f7e23eff5d153346890f242a94b78bad6736b
2024-04-01 16:37:20 +09:00
Kiyoung Kim
1db4a74a59 Remove VNDK information from Rust, etc, and sysprop tests
VNDK is deprecated in 24Q2, so soong should be tested with no device and
platform vndk versions. This change removes all VNDK related tests and
VNDK versions from soong-etc, soong-rust and soong-sysprop tests.

Bug: 330100430
Test: m nothing --no-skip-soong-tests passed
Change-Id: Ie34d23f0facab31078de54682f7cc78d37fcd4be
2024-04-01 15:53:58 +09:00
Nelson Li
1f96994e53 Support pyhon_rule_defaults in Soong
This change adds support for `python_rule_defaults` in Soong, allowing
different targets to reuse the same dependencies. This resolves the
issue where different dependencies could not be synchronized due to the
lack of `python_rule_defaults` in Soong.

Bug: 331886818
Test: 1. Add phony_rule_defaults module in the Android.bp
      2. Add the module in `defaults`
Change-Id: If3579ea685529858567748e6f34bcf7c5477bcfc
2024-04-01 11:40:21 +08:00
Jiyong Park
eaac823f19 Add android_system_image_defaults
Bug: 330665150
Test: go test ./... under filesystem
Change-Id: Id32e6563491a3d129042de4a9517c545543a022d
2024-03-31 21:27:45 +09:00
Jiyong Park
4d4eb59a2b Merge "fix: required deps of phony modules are correctly tracked" into main 2024-03-30 13:48:48 +00:00
Ronald Braunstein
c654ad162c Merge "Add test_module_config_host" into main 2024-03-29 22:15:08 +00:00
Jesse Melhuish
ec60e25a1c Allow Multilib in override_apex
Test: m nothing --no-skip-soong-tests
Test: go test apex_text.go
Bug: 246854990
Change-Id: Id6e31c63acd87466a4436288d550ce6b298c677d
2024-03-29 21:13:57 +00:00
Spandan Das
08e90c2718 Fixes for run_integration_tests.sh
This script runs some useful integration tests, but is currently broken
at ToT. This CL enables us to rerun this script successfully.

Details
1. Remove the scripts related to bp2build/b/mixed_builds. These modes
   have been/are on the verge of deletion from soong
2. Remove the comparisision scripts for soong and bazel built artifcats,
   for the same reason
3. Add a TARGET_RELEASE to androidmk_test.sh
4. Add a TARGET_PRODUCT to o/s/build.ninja, since the generated .ninja files
   now have a product-specific suffix.
5. Remove a test that checks that globs are not generated in the first
   clean run. We always generate the glob file now (aosp/2893286)

Test: build/soong/tests/run_integration_tests.sh
Change-Id: I39f6706ab2a81a7b1b2e90d43195bc3e2c7a5c08
2024-03-29 19:00:20 +00:00
Ivan Lozano
e2524fb87e Merge "rust: Remove unnecessary escaping in grep call" into main 2024-03-29 16:31:44 +00:00
Ted Bauer
6ef40dbce6 Add logging dependencies to Rust aconfig APIs
Test: go test
Change-Id: I17c098f6b83c442554e49b6b802f11c97f94ec76
2024-03-29 14:05:05 +00:00
Kiyoung Kim
82488ca457 Merge "Remove VNDK information from CC and APEX tests" into main 2024-03-29 04:37:25 +00:00
Jiyong Park
9c540c82d4 fix: required deps of phony modules are correctly tracked
ArchType.Multilib of native modules are either lib32 or lib64.
Arch-neural modules have "" not "common".

Bug: 321626681
Test: go test ./...
Change-Id: Ie7e6a5203e9f671487dbf32ea2343ada7407a28f
2024-03-29 12:53:32 +09:00
Kiyoung Kim
149f8e1502 Merge "Remove vendor_snapshot_test" into main 2024-03-29 02:50:32 +00:00
Treehugger Robot
4fcfd0123c Merge "Improve errors when compiling python code" into main 2024-03-29 02:50:30 +00:00
Jooyung Han
3520b9488e Merge "VINTF manifests in apex don't require extension" into main 2024-03-29 02:37:19 +00:00
Treehugger Robot
8b80173e23 Merge "Add support for prebuilt_usr_hyphendata type" into main 2024-03-29 02:30:31 +00:00
Kiyoung Kim
b54c4b4a96 Merge "Ensure java level inter partition dependency with VNDK deprecation." into main 2024-03-29 00:42:09 +00:00
Cole Faust
5a8f533a29 Improve errors when compiling python code
Now a stacktrace involving precompile_python.py won't be shown,
and it will show all errors instead of just the first one.

Bug: 331488610
Test: Presubmits
Change-Id: I47376ca6764c0f84d1aaf5db329664e20143640a
2024-03-28 17:31:21 -07:00
Jihoon Kang
472f73fdac Add API compatilibility flags to the exportable stubs
The API compatibility flags allow the APIs that have moved between API
surfaces to be correctly represented in the stub artifacts by passing
the previously released set of APIs and removed APIs. These information
should be passed to metalava when generating the exportable stubs, so
that the APIs that move between the API surfaces are not blocked in the
hiddenapi flags.

Test: patch to 24Q3-beta-release, lunch sdk-trunk_staging-eng && m sdk
dist and ensure that the expected methods are not blocked in the
hiddenapi flags
Bug: 330753520

Change-Id: I030b0a46b09f0cea026fedc879f10d4edfd38ac3
2024-03-28 23:38:02 +00:00
Treehugger Robot
1c3675503c Merge "Fix some non-determinism in aconfigMerge operation" into main 2024-03-28 23:35:10 +00:00