Commit Graph

85255 Commits

Author SHA1 Message Date
Neill Kapron
d47cfab05b Merge changes from topic "libbpf_defaults" into main
* changes:
  Soong: libbpf_prog: add support for header_libs
  Soong: libbpf_prog: Add defaults support
2024-09-17 23:03:33 +00:00
Florian Mayer
5c441cea7a Run bionic tests for cc toolchain changes
Change-Id: Id26e2f6ff360abe35ead3a47055ba69e10ace033
2024-09-17 21:25:14 +00:00
Treehugger Robot
809aaeb90b Merge changes I41978037,I19e8a9e8 into main
* changes:
  Properly initialize android_system_image modules
  Add otherModuleProvider to ConfigurableEvaluatorContext
2024-09-17 20:07:08 +00:00
Colin Cross
e95232426d Merge "Convert test mutators to TransitionMutators" into main 2024-09-17 19:05:06 +00:00
Neill Kapron
3cc44de313 Soong: libbpf_prog: add support for header_libs
Add header_libs support for libbpf_prog modules.

Test: TH / manual
Bug: 359646531
Change-Id: I9e705645582ec12bfa0a2e388d0049bb472456e3
Signed-off-by: Neill Kapron <nkapron@google.com>
2024-09-17 18:33:46 +00:00
Cole Faust
2cfe696f4c Properly initialize android_system_image modules
android_system_image just passed its embedded filesystem module to
InitAndroidModule (transitively via initFilesystemModule). This meant
that ModuleBase.module was pointing to the filesystem module, not
the system image module. This was a problem for the new "changeable
configuration" feature I'm working on, but you can also more readily
see the issue if you add a GenerateAndroidBuildActions function to
android_system_image: it won't be called.

Bug: 361816274
Test: Presubmits
Change-Id: I41978037b81910309a000dc1bba327e513ba5dce
2024-09-17 11:31:14 -07:00
Makoto Onuki
a191ef3c54 Merge "Make compat-config to generate output files too" into main 2024-09-17 18:29:23 +00:00
Treehugger Robot
2ad497a39d Merge "Soong: BPF: add defaults support and local include" into main 2024-09-17 18:25:12 +00:00
Treehugger Robot
1c8c5698ec Merge "Pass the common sources rsp file as --common_srcs to extractor" into main 2024-09-17 17:49:54 +00:00
Colin Cross
1531a12d2d Merge "Convert arch and os mutators to TransitionMutators" into main 2024-09-17 17:06:14 +00:00
Makoto Onuki
ca678c4a36 Make compat-config to generate output files too
Flag: EXEMPT host test change only
Bug: 367706429
Test: m nothing --no-skip-soong-tests
Test: `m ravenwood-runtime` and make sure out/host/linux-x86/testcases/ravenwood-runtime/ravenwood-data/
    has framework-platform-compat-config.xml and services-platform-compat-config.xml
Change-Id: I92b545c480890815cd886b8ecf50ed99ffe7eea1
2024-09-17 09:53:33 -07:00
Ulya Trofimovich
9d96d1f186 Merge "Revert^12 "Enable dex container (DEX v41) for the whole system"" into main 2024-09-17 14:01:55 +00:00
Colin Cross
d27205e8da Convert test mutators to TransitionMutators
Convert various mutators in tests to TransitionMutators.

Bug: 319288033
Flag: EXEMPT refactor
Test: all soong tests pass
Change-Id: I1da55889c391582a7c825c118c5988ec27820237
2024-09-16 17:00:39 -07:00
Colin Cross
8bbc3d5a30 Convert arch and os mutators to TransitionMutators
Replace archMutator and osMutator with TransitionMutators.

Bug: 319288033
Flag: EXEMPT refactor
Test: all soong tests pass
Test: no change to out/soong/*.ninja
Change-Id: I92a4d7c895dd79f1dd8064d0ca90e7010b563525
2024-09-16 17:00:39 -07:00
Cole Faust
55b56feb86 Add otherModuleProvider to ConfigurableEvaluatorContext
So that it can make decisisons based on a provider set by the
base config mutator.

Bug: 361816274
Test: m nothing
Change-Id: I19e8a9e800dfabcd05740f9c0ed5db833c5b2377
2024-09-16 15:10:05 -07:00
Neill Kapron
4f1f049f5c Soong: libbpf_prog: Add defaults support
Add defaults support for libbpf_prog module type.

Test: TH / manual
Bug: 359646531
Change-Id: Idc2977d3cf6efe62968e0eac9fc592d0cf0b3beb
Signed-off-by: Neill Kapron <nkapron@google.com>
2024-09-16 20:12:14 +00:00
Ulya Trofimovich
5bb46810a5 Revert^12 "Enable dex container (DEX v41) for the whole system"
This reverts commit 78fccd9380.

Reason for revert: test failure in can no longer be reproduced.

Bug: 353452237
Change-Id: I7cf926342efc612b4026d89df12078c018ede7b9
2024-09-16 18:58:53 +00:00
Yifeng Zeng
d141912806 Enable Rust host coverage.
Bug: 297082598
Bug: 330591720
Test: atest logger_host_unit_tests --experimental-coverage
Change-Id: Iec6db35b88e2812d3af69863e74b0acf138b04df
2024-09-14 05:21:18 +00:00
Treehugger Robot
0bfceee178 Merge "Prevent evaluating configurable properties before the defaults mutator" into main 2024-09-13 23:56:18 +00:00
Treehugger Robot
e372d287c0 Merge "[Ravenwood] Support fonts files and data files" into main 2024-09-13 23:27:25 +00:00
Maciej Żenczykowski
d0ea163941 Merge "BPF: rename bpf_defaults to bpf_cc_defaults" into main 2024-09-13 22:15:27 +00:00
Spandan Das
67136e14f3 Pass the common sources rsp file as --common_srcs to extractor
This additional metadata allows the indexer to differentiate between
platform specific and platform agnostic kotlin code.

Bug: 3266381
Test: ran the indexer on `kotlinx_serialization_core` java_library
Change-Id: I860552808198cafa95fe0d5b6faa725b985e24d0
2024-09-13 22:12:45 +00:00
Treehugger Robot
ad6a20f3a1 Merge "Add links to partner docs for presigned apks" into main 2024-09-13 21:16:42 +00:00
Aditya Kumar
e5cb9c659b Merge "Disable -Wno-deprecated-dynamic-exception-spec until the warning is fixed in libc++abi header files" into main 2024-09-13 21:10:04 +00:00
John Wu
680cd73e1a [Ravenwood] Support fonts files and data files
Add support to include font files into ravenwood_libgroup. Also make ravenwood data property to accept paths instead of module name. 

Bug: 292141694
Flag: EXEMPT host side change only
Test: $ANDROID_BUILD_TOP/frameworks/base/ravenwood/scripts/run-ravenwood-tests.sh
Change-Id: Ida5ef0230d2cc59fa1209199168c6c35e4842fbd
2024-09-13 20:59:05 +00:00
Cole Faust
d706709bf0 Prevent evaluating configurable properties before the defaults mutator
So that we can change the configuration after the defaults mutator
has run.

Bug: 361816274
Test: Presubmits
Change-Id: I550088b2555d275a86b5dd4d57e85a9ece859233
2024-09-13 13:37:59 -07:00
Treehugger Robot
c2ea958b3d Merge changes from topic "flag_application_manifest" into main
* changes:
  Support multiple <application> or <uses-sdk> elements in manifest_*.py
  Fix manifest_fixer.py warnings
2024-09-13 19:52:44 +00:00
Cole Faust
ce6ddd6e24 Add links to partner docs for presigned apks
So if a partner gets this error they can find the script and see
links to documentation.

Test: Presubmits
Change-Id: I50cbe4770e9619fb67a7a586fa6d2210c67d4650
2024-09-13 11:51:02 -07:00
Colin Cross
e1ab849b39 Support multiple <application> or <uses-sdk> elements in manifest_*.py
Manifests may now have multiple copies of elements if they are
disambiguated with android:featureFlag attributes.  Remove the
restrictions on duplicate elements from manifest_check.py and
manifest_fixer.py, and instead iterate over all matching elements.

Test: manifest_check_test.py, manifest_fixer_test.py
Bug: 365170653
Flag: EXEMPT bugfix
Change-Id: Ib577439d03a808a20a5fcc3e15a3117e0970d729
2024-09-13 11:20:21 -07:00
Neill Kapron
dfc02f81fc BPF: rename bpf_defaults to bpf_cc_defaults
With the addition of defaults to the bpf soong module (see aosp/3249485
), the name `bpf_defaults` will be used to define defaults for bpf
program compilation. While there are separate soong namespaces for
module types and module names, rename the existing bpf_defaults
cc_defaults to bpf_cc_defaults for clarity.

While we're at it, add -Wextra, and cleanup unnecessary cflags in
clauses which use bpf_cc_defaults.

Test: TH
Change-Id: Ib5f453ce33b13c698e8b91088bc59f8c6719c892
Signed-off-by: Neill Kapron <nkapron@google.com>
2024-09-13 17:55:12 +00:00
Treehugger Robot
05d9069051 Merge "Fix reanalysis after full build" into main 2024-09-13 17:41:24 +00:00
Colin Cross
893528a4c9 Fix reanalysis after full build
Blueprint bootstrap and Soong each create rules to install
blueprint_go_binary modules to the same location, but with different
command lines.  Binaries used during bootstrap are installed using
the bootstrap rule, but then get reinstalled during a full build via
the blueprint_tools phony that is a dependency of droid.  This
changes the command line used for the rule stored in .ninja_log,
and then on the next bootstrap ninja will rerun the binaries,
triggering reanalysis.

As a quick fix, don't create install rules for loadplugins and
soong_build.  A more permanent fix may be to move the bootstrap
installation to a different location, but that will require more
testing.

Bug: 366291149
Test: m blueprint_tools && m blueprint_tools
Flag; EXEMPT bugfix

Change-Id: Ib7f2910976f4b5e6add2128ce0b2a5d10445a53c
2024-09-12 23:08:16 -07:00
Treehugger Robot
24627096c1 Merge "Add SOONG_DISABLE_CLIPPY environment variable" into main 2024-09-13 05:49:00 +00:00
Jihoon Kang
437f87f0c7 Merge "Find subdir aconfig_values from srcs" into main 2024-09-13 03:56:32 +00:00
Treehugger Robot
6c10c36d0a Merge "linker_config_src in filesystem may read filegroup" into main 2024-09-13 02:19:03 +00:00
Jihoon Kang
4fbee9af0b Find subdir aconfig_values from srcs
This change supports adding dependencies from the aconfig_value_set
module to the aconfig_values modules from `srcs`, which are the
paths to the Android.bp files where the aconfig_value modules are
defined.

Test: m nothing --no-skip-soong-tests
Bug: 365827715
Change-Id: Idd5f1d9c2625a6362dbaf3adba0a74406e3a9928
2024-09-12 23:48:19 +00:00
Dennis Shen
01efb83420 Treat system_ext as system container
Bug: b/365135457
Test: m
Change-Id: Ic8fd60c0e1045f190b6608931ca1d65a784026f0
2024-09-12 23:31:49 +00:00
Chris Wailes
abc17eac1a Add SOONG_DISABLE_CLIPPY environment variable
This environment variable will be used for testing the Rust toolchain
for correctness before updating the Android codebase to resolve new
lints.

Test: Introduce lint
Test: SOONG_DISABLE_CLIPPY=true m out/soong/.intermediates/frameworks/minikin/rust/libminikin_rust_ffi/android_arm_armv8-a_rlib_rlib-std/libminikin_rust_ffi.rlib.clippy
Change-Id: If7236c7f16a3e0a0b27a90577211549f2dc1a344
2024-09-12 15:37:34 -07:00
Treehugger Robot
d4771aa267 Merge "Allow multiple ninja implementations" into main 2024-09-12 22:09:58 +00:00
Treehugger Robot
c379ea0fd4 Merge "Don't evaluate the enabled property in a defaultable hook" into main 2024-09-12 20:15:20 +00:00
Aditya Kumar
2c6b4acb87 Disable -Wno-deprecated-dynamic-exception-spec until the warning is fixed in libc++abi header files
Test: mmma art/libnativeloader

Bug: b/366180429
Change-Id: Ie77f9dc674224044d5c7078db891f88e42a52a19
2024-09-12 20:15:07 +00:00
Spandan Das
a7b916b50c Merge "Use -language-version 1.9 in the kotlinKythe build rule" into main 2024-09-12 19:52:30 +00:00
LaMont Jones
ece626ccac Allow multiple ninja implementations
This permits easier testing and comparison between different ninja
implementations.

Bug: 362926979
Bug: 318434287
Test: manual
Change-Id: Ic058338d0a2fd8c988794a0781dcc93c0f4c03e3
2024-09-12 12:45:27 -07:00
Treehugger Robot
c5d2456d8b Merge "Fix a bug in the log directory cleanup logic." into main 2024-09-12 19:02:44 +00:00
Cole Faust
8eeae4bbbe Don't evaluate the enabled property in a defaultable hook
So that we can decide the configuration after defaults are evaluated.
Instead, pass the enabled property on to submodules.

Bug: 361816274
Test: m nothing --no-skip-soong-tests
Change-Id: I853d557ed022f7434287cea0a2a19e684b59e145
2024-09-12 11:51:04 -07:00
Spandan Das
3d6c6d9c76 Use -language-version 1.9 in the kotlinKythe build rule
There are some instances of .kt code in android platform that are not
fully compatible with kotlinc > 2. To account for this version skew when
generating xrefs, implicitly add `-language-version 1.9` to the args in
the .kzip file. The main kotlinc build rules remain the same.

This value has been picked manually by running
`external/kotlinc/bin/kotlinc -version` at ToT

Bug: 265428637
Test: verified that `-language-version 1.9` is added to the build
command of the .kzip files
Test: ran the indexer locally on the .kzip of `PermissionController-lib`
(this android_library contains .kt code that does not compile with
verison >2)

Change-Id: Icfb72800404d83f63204de23a1ec34b40ee05847
2024-09-12 18:20:59 +00:00
Spandan Das
6556d043bd Merge changes from topic "kotlin_kythe" into main
* changes:
  Add kotlin kzips to build_kzip.bash
  Create .kzip files for kotlin translation units
2024-09-12 18:14:14 +00:00
Yaowen Mei
d9108d2d34 Fix a bug in the log directory cleanup logic.
This CL fix the bug that shouldCleanupRBELogsDir() never return true.

The way how shouldCleanupRBELogsDir() use to work is it will return true only if `RBE_proxy_log_dir` flag is not set.

But CI build always got this flag from gcl file, and developer build always got this flag set from ui/build/rbe.go (http://shortn/_K604iWNYkd). So there is never a case this shouldCleanupRBELogsDir() return true. That is to say, we never clean up
RBELogsDir by ourselves.

The reason why this is not a concern is that soong will automatically delete the out/soong/.temp folder every time when user run `m` or `lunch`, and the default RBELogsDir use to be `out/soong/.temp/rbe`. So soong is helping us to clean the logs before.


Previously, I merged this CL: https://r.android.com/3192211 to support running `lunch` in two terminals. In that CL, I moved the auto created RBELogsDir one level up to `out/soong/rbe`. This is causing a problem because RBELogsDir never get cleaned.

This CL will fix the shouldCleanupRBELogsDir() method, after this merged in, 1) if a user didn't set the `RBE_proxy_log_dir` flag, the logs in `out/soong/rbe` will be cleaned each time when running `m`, but `lunch` will not touch `out/soong/rbe`, so we still support running `lunch` in different terminals. 2) If user set `RBE_proxy_log_dir` flag to anything rather than `out/song/rbe`, the directory will not be cleaned by running `m`; 3) we have updated our doc everywhere that `out/soong/rbe` is re-client's default log dir, so I think it should be expected if user set `RBE_proxy_log_dir=out/soong/rbe`, then the logs will be deleted when next time `m` invoked, same as if they set `RBE_proxy_log_dir=out/soong/.temp/rbe` before.


Test: abtd run is green: http://shortn/_KqTvQelstP, local build with multiply lunch is not affected, and running m after a build can clean the out/soong/rbe directory.
Bug: 362798954
Change-Id: I38a7ad650fc59ad06716c5be7de6ecc61ead8eef
2024-09-12 18:08:06 +00:00
Treehugger Robot
167230037c Merge "Introduce a util method PrettyConcat" into main 2024-09-12 17:10:11 +00:00
Treehugger Robot
82e99ce373 Merge "Wrap blueprint_go_binary and bootstrap_go_package into android.Modules" into main 2024-09-12 15:46:51 +00:00