Commit graph

28814 commits

Author SHA1 Message Date
Treehugger Robot
f13d0b2f22 Merge "Revert^2 "Reuse license metadata files from Soong"" 2021-12-11 03:32:18 +00:00
Pirama Arumuga Nainar
b1b4e1e38b Set a BIONIC_COVERAGE .mk variable
Bug: http://b/194128476
Bug: http://b/210012154

Set BIONIC_COVERAGE to true if coverage instrumentation is enabled for
bionic/libc.  This is used in system/core/rootdir/Android.mk to set
the default LLVM_PROFILE_FILE environment.

Test: Run tests with this topic and verify coverage still works and also
test memory-mapped coverage (death tests, JNI code in CTS)

Change-Id: I585f3e43dfcb82dd3c211051d354dd79ee77b1fb
2021-12-10 15:29:37 -08:00
Colin Cross
2e075808dd Merge "Revert "Reuse license metadata files from Soong"" am: 91a9483e87
Original change: https://android-review.googlesource.com/c/platform/build/+/1918946

Change-Id: I85bbf851be4f5d2d3884f2c4652e32b0bcbd59b3
2021-12-10 23:20:49 +00:00
Colin Cross
71d9919322 Revert^2 "Reuse license metadata files from Soong"
81b167693f

Change-Id: Iff45cffb1f2b9d01cec70d96e34f46d35bb37842
2021-12-10 23:05:02 +00:00
Colin Cross
91a9483e87 Merge "Revert "Reuse license metadata files from Soong"" 2021-12-10 23:04:45 +00:00
Colin Cross
81b167693f Revert "Reuse license metadata files from Soong"
Revert "Escape Host*Variable contents"

Revert submission 1899703

Reason for revert: b/210158272
Reverted Changes:
I142c19284:Reuse license metadata files from Soong
Ife89b8f23:Add dependency license annotations
I8e7410837:Build license metadata files in Soong

Change-Id: Id9d66c01453aebe8a52eaa6628e9933a990d4c2f
2021-12-10 23:03:08 +00:00
Cole Faust
98a7011088 Merge "Strip ODM_MANIFEST_SKUS" am: 01e022369b
Original change: https://android-review.googlesource.com/c/platform/build/+/1917097

Change-Id: I37ee8f0df0bcb212e0fc3add6b069e5857614747
2021-12-10 22:05:31 +00:00
Colin Cross
b48261121e Merge "Reuse license metadata files from Soong" am: 6cf8ec77cc
Original change: https://android-review.googlesource.com/c/platform/build/+/1900116

Change-Id: Id5db06a34777ff0a2bca39ffa0e083ca2a131a3d
2021-12-10 22:04:39 +00:00
Cole Faust
01e022369b Merge "Strip ODM_MANIFEST_SKUS" 2021-12-10 22:02:22 +00:00
Colin Cross
6cf8ec77cc Merge "Reuse license metadata files from Soong" 2021-12-10 21:43:49 +00:00
Inseob Kim
7c708e2d27 Merge "Add BoardPlatVendorPolicy to soong config" am: f09eddd531
Original change: https://android-review.googlesource.com/c/platform/build/+/1914612

Change-Id: I15f4771b72598028a380d15ca8f1c3421b07890d
2021-12-10 12:29:48 +00:00
Inseob Kim
f09eddd531 Merge "Add BoardPlatVendorPolicy to soong config" 2021-12-10 12:13:36 +00:00
Inseob Kim
51c455bdb2 Refactor sepolicy version related codes
1. Move BOARD_SEPOLICY_VERS to build/make/core/config.mk where
PLATFORM_SEPOLICY_VERSION is set.

2. Remove hard-coded versions for the treble tests.

Test: build
Change-Id: Iab338a1f16855205d62312d4247a15ea766be1fe
2021-12-10 18:36:18 +09:00
Cole Faust
3203cba181 Export words function
It will now be generated in mk2rbc as part of
foreach expressions.

Bug: 201700692
Test: None
Change-Id: I400563946d46d7cac9be901a80470248990800bd
2021-12-09 14:26:03 -08:00
Cole Faust
d4fcff6db8 Merge "Allow multiple patterns in rblf_wildcard" am: 598cbbcde7
Original change: https://android-review.googlesource.com/c/platform/build/+/1915258

Change-Id: Ib9da4c5eb2ea775fb52b67ee4a6558aee4f0e5dc
2021-12-09 21:50:21 +00:00
Cole Faust
598cbbcde7 Merge "Allow multiple patterns in rblf_wildcard" 2021-12-09 21:32:53 +00:00
Cole Faust
c8c516a89b Strip ODM_MANIFEST_SKUS
Otherwise it gets a different value when using starlark
board config, causing the ninja files to differ.

Bug: 201700692
Test: ./build/bazel/ci/rbc_regression_test.sh -b aosp_crosshatch_car-userdebug
Change-Id: I55870f031b779202db720f10d7d502f9d868e1f6
2021-12-09 10:30:19 -08:00
Cole Faust
fdff6b1e9c Allow multiple patterns in rblf_wildcard
This is to match the functionality of make's $(wildcard)

Bug: 201700692
Test: go test
Change-Id: Ib20c4a4aa9642a2d76b5da5c7accd60e6b91c8fc
2021-12-08 17:52:40 -08:00
Treehugger Robot
48b1b7e6f0 Merge "Explicitly set EROFS compression parameter" am: 1f9408b2b2
Original change: https://android-review.googlesource.com/c/platform/build/+/1908390

Change-Id: I797ee4f2cf2bdc2b6f0e2107e28a57a4e6c99b10
2021-12-09 01:11:02 +00:00
Treehugger Robot
1f9408b2b2 Merge "Explicitly set EROFS compression parameter" 2021-12-09 00:40:36 +00:00
Dan Willemsen
b66a55ea05 Merge "Add basic Darwin+Arm64 support as HOST_CROSS" am: e808bc4a09
Original change: https://android-review.googlesource.com/c/platform/build/+/1883492

Change-Id: If566a5f3a588db74cc6d54d4c107c0f1c88bea4c
2021-12-08 22:59:34 +00:00
Dan Willemsen
8820840d57 Add basic Darwin+Arm64 support as HOST_CROSS
Soong will use this to turn on universal binary support (X86_64 + Arm64
in the same binary).

Bug: 203607969
Test: m sdk-repo-platform-tools sdk-repo-build-tools on Mac
Change-Id: I04612136a42e85f4add95202ce20e741d9aaa302
2021-12-08 09:26:27 -08:00
Inseob Kim
d0f600a074 Add BoardPlatVendorPolicy to soong config
Bug: 205924657
Test: build
Change-Id: I89697a82c6d288576ae066f82a067383ccd57e2e
2021-12-08 22:53:02 +09:00
Treehugger Robot
37d01f684d Merge "Add missing apksigner dependency" am: 1295bc5138
Original change: https://android-review.googlesource.com/c/platform/build/+/1891388

Change-Id: Ie10a161857ad6ecd4d3d5f2cf5a43a5f2c7a0e00
2021-12-07 12:57:53 +00:00
Treehugger Robot
1295bc5138 Merge "Add missing apksigner dependency" 2021-12-07 11:43:06 +00:00
Treehugger Robot
793100509c Merge "Revert "Revert "Move meta_lic files into per-module intermediates directories""" am: 0d8d378bd4
Original change: https://android-review.googlesource.com/c/platform/build/+/1910142

Change-Id: I36aa20e6861144f547955e4750c43f1cd011ffeb
2021-12-07 04:52:20 +00:00
Treehugger Robot
0d8d378bd4 Merge "Revert "Revert "Move meta_lic files into per-module intermediates directories""" 2021-12-07 04:33:01 +00:00
Treehugger Robot
9498b39594 Merge "[cc/sanitize] Re-enable new pass manager for fuzzer targets" am: e813a4a023
Original change: https://android-review.googlesource.com/c/platform/build/+/1908951

Change-Id: Ief74d2d1faf733bab6a86fed95cceea956c4ad03
2021-12-06 21:42:56 +00:00
Treehugger Robot
e813a4a023 Merge "[cc/sanitize] Re-enable new pass manager for fuzzer targets" 2021-12-06 21:40:10 +00:00
Cole Faust
d8b85632e3 Merge "Pass input variables to product config" am: 8fb2d83457
Original change: https://android-review.googlesource.com/c/platform/build/+/1908233

Change-Id: I182cdec2014ebf8409ad192c1ffd82b2cda7cf5f
2021-12-05 04:05:50 +00:00
Cole Faust
8fb2d83457 Merge "Pass input variables to product config" 2021-12-05 03:43:24 +00:00
Treehugger Robot
7939f4bca2 Merge "Add Soong variable for optimizing system Java" am: 742874e0e6
Original change: https://android-review.googlesource.com/c/platform/build/+/1896612

Change-Id: I0ca5c029e3bc6213179d67f923cf962b6c0474eb
2021-12-04 01:25:26 +00:00
Treehugger Robot
742874e0e6 Merge "Add Soong variable for optimizing system Java" 2021-12-04 01:07:34 +00:00
Colin Cross
4f8dd6fe45 Reuse license metadata files from Soong
Copy the license metadata files from Soong if they've already
been built.

Bug: 207445310
Test: m checkbuild
Change-Id: I142c192843e94b018079809bd596ff81136b2de3
2021-12-03 22:47:11 +00:00
Colin Cross
52a0c97e5a Revert "Revert "Move meta_lic files into per-module intermediates directories""
This reverts commit e41ad14f58.

Change-Id: I77211030b657b894002a1a1bded773b3c4b0334a
2021-12-03 22:46:20 +00:00
Jiyong Park
160149e42d Merge "Reland: Add NEED_AIDL_NDK_PLATFORM_BACKEND" 2021-12-03 10:56:52 +00:00
Cole Faust
f1f49bb910 Pass input variables to product config
Passing variables via a makefile instead of
rblf_cli / rblf_env allows us to give them correct
types while converting the makefile to starlark,
as opposed to the variables always being strings
when given via rblf_cli / rblf_env.

This also allows us to remove some hand-converted
starlark code.

Bug: 201700692
Test: ./out/soong/rbcrun ./build/make/tests/run.rbc
Change-Id: I58c4f20b29171c14e5ae759beb26a849426f6961
2021-12-02 20:47:31 -08:00
Colin Cross
d821c63926 Merge "Revert "Move meta_lic files into per-module intermediates directories"" am: ccb353501d
Original change: https://android-review.googlesource.com/c/platform/build/+/1908224

Change-Id: Iffd05ce12c5338ebc545e6f3789431beae569bca
2021-12-03 01:06:06 +00:00
Colin Cross
ccb353501d Merge "Revert "Move meta_lic files into per-module intermediates directories"" 2021-12-03 00:46:31 +00:00
Colin Cross
e41ad14f58 Revert "Move meta_lic files into per-module intermediates directories"
This reverts commit 44858d35ce.

Reason for revert: b/208892388

Change-Id: I058e988a8949ed9aa1fac086a69b37a053681982
2021-12-03 00:44:23 +00:00
Jared Duke
2819a5beed Add Soong variable for optimizing system Java
Introduce a Soong variable to allow selective enabling of Java
optimizations for platform targets. This will be used initially
to control optimizations (and shrinking) for system server + sysui.

Opting in to optimizations can be achieved with either:
  * Env:
export SYSTEM_OPTIMIZE_JAVA=true
  * Make:
$(call add_soong_config_var_value,ANDROID,SYSTEM_OPTIMIZE_JAVA,true)

Note that the actual framework build rule changes to hook into this
variable will land separately.

Bug: 203088572
Test: `SYSTEM_OPTIMIZE_JAVA=true m` (observe env variable change log)
Change-Id: I959985bdff394c2445cb1632116846a8d2f5443d
2021-12-02 15:56:10 -08:00
Colin Cross
d24ec61b85 Merge "Move meta_lic files into per-module intermediates directories" am: dd93bd5b72
Original change: https://android-review.googlesource.com/c/platform/build/+/1906234

Change-Id: Id0864e473fc41db29f41284006858495476a26a9
2021-12-02 23:15:01 +00:00
Colin Cross
dd93bd5b72 Merge "Move meta_lic files into per-module intermediates directories" 2021-12-02 22:54:05 +00:00
Treehugger Robot
e802f38861 Merge "Remove 26.0 and 27.0 compat support" am: 5a0cef1c00
Original change: https://android-review.googlesource.com/c/platform/build/+/1904274

Change-Id: I299faad441b394d731b7ec0526b0954dfe995c1a
2021-12-02 06:46:29 +00:00
Treehugger Robot
5a0cef1c00 Merge "Remove 26.0 and 27.0 compat support" 2021-12-02 06:26:58 +00:00
Pirama Arumuga Nainar
49f052d155 [cc/sanitize] Re-enable new pass manager for fuzzer targets
Bug: http://b/133876586

This was turned off but the upstream change fixing this has been long
part of the Android toolchain.

Test: Output of
  m aidl_parser_fuzzer; readelf aidl_parser_fuzzer | grep -c sancov
hasn't changed.

Change-Id: I1d5f9c94cebad74ee00adc1290bbf425bb5c4cd3
2021-12-01 20:50:38 -08:00
Jiyong Park
c99f65fa6c Reland: Add NEED_AIDL_NDK_PLATFORM_BACKEND
The config variable is used to force the generation of the AIDL
ndk_platform backend which will eventually be removed in favor of the
ndk backend. The switch is needed as an escape hatch for some devices
whose BSP (outsourced and thus hardly modifiable) depends on the
ndk_backend libraries.

Bug: 161456198
Test: m

Merged-In: Iba8633263ae649af783e94b01f5c1b5c6e042948
Change-Id: I8b73a6a1e5169c35daf333316857b3c3b110a0f7
2021-12-02 13:16:13 +09:00
Android Build Coastguard Worker
9e5ff9876d Version bump to SQ1A.220105.002 [core/build_id.mk]
Change-Id: I746a684e40416cc5151c63ef075d4244884720d1
2021-12-02 00:02:44 +00:00
Cole Faust
c8305d10b7 Merge "Strip more board config variables" am: b3eb2087df
Original change: https://android-review.googlesource.com/c/platform/build/+/1905890

Change-Id: Ia50a0ef99f533612a8b4cc3c33df424983b1566c
2021-12-01 23:50:07 +00:00
Cole Faust
b3eb2087df Merge "Strip more board config variables" 2021-12-01 23:30:32 +00:00
Treehugger Robot
109643a5cc Merge "Add 32.0 to PLATFORM_SEPOLICY_COMPAT_VERSIONS" am: b5373a9845
Original change: https://android-review.googlesource.com/c/platform/build/+/1906151

Change-Id: I1d8b4d2c3212d2235c278a951d7808a4a1294068
2021-12-01 23:25:54 +00:00
Treehugger Robot
b5373a9845 Merge "Add 32.0 to PLATFORM_SEPOLICY_COMPAT_VERSIONS" 2021-12-01 23:10:38 +00:00
Cole Faust
15ff08eaa4 Merge "Correctly copy the board configuration input variables" am: f900cb4c12
Original change: https://android-review.googlesource.com/c/platform/build/+/1905476

Change-Id: I490a30c0978fb7aed58492977b26e64d10504f86
2021-12-01 22:56:22 +00:00
Colin Cross
44858d35ce Move meta_lic files into per-module intermediates directories
Store the meta_lic files in the per-module intermediates directories
to avoid conflating multiple variants for the same module, for example
host and device.

Bug: 207445310
Test: m checkbuild
Change-Id: I2b0ca22c1f7b069f79d2026707be3294c488f6de
2021-12-01 14:38:13 -08:00
Cole Faust
f900cb4c12 Merge "Correctly copy the board configuration input variables" 2021-12-01 22:37:09 +00:00
Kelvin Zhang
37d4929586 Explicitly set EROFS compression parameter
OTA will need to know the compression parameter used to construct EROFS
images. Currently, mkfs.erofs uses lz4hc,9 if the user didn't specify
one. But mkfs's default behavior is subject to change in future
versions. Therefore, explicitly specify the compression parameters so
OTA tooling can properly encode/decode erofs images.

Test: th
Change-Id: Ibbf67502827ee79437b766349be289048e685759
2021-12-01 14:21:24 -08:00
Colin Cross
0238985e0f Merge "Remove duplicate includes of BUILD_NOTICE_FILE" am: 3db143c452
Original change: https://android-review.googlesource.com/c/platform/build/+/1906235

Change-Id: Ic30b2455c2155cac186caf032ddc66e09fbb5488
2021-12-01 22:02:23 +00:00
Colin Cross
3db143c452 Merge "Remove duplicate includes of BUILD_NOTICE_FILE" 2021-12-01 21:08:12 +00:00
Cole Faust
3be5b72ad6 Correctly copy the board configuration input variables
dict(**h[0]) was only copying the top level dictionary
object, but not any other dictionaries/lists inside of
it. This was causing us to not find all the changes to
variables the board configuration was making, and so
some variables were not included in the output.

Bug: 201700692
Test: ./build/bazel/ci/rbc_regression_test.sh mainline_system_x86_64-userdebug
Test: ./out/soong/rbcrun ./build/make/tests/run.rbc
Change-Id: I4467eead7e597f6f49119a8c4832126f39d646e7
2021-12-01 11:06:23 -08:00
Jiakai Zhang
4207daaf8e Merge "Add a variable to specify standalone system server jars." am: 1ecb2f952c
Original change: https://android-review.googlesource.com/c/platform/build/+/1874113

Change-Id: I1ba1cedc1da159c654675f7895e31c4ac8d6e92a
2021-12-01 12:37:48 +00:00
Jiakai Zhang
1ecb2f952c Merge "Add a variable to specify standalone system server jars." 2021-12-01 12:29:37 +00:00
Treehugger Robot
52057e2add Merge "Define $(PRODUCT_OUT) before running the board config" am: 9118768352
Original change: https://android-review.googlesource.com/c/platform/build/+/1906551

Change-Id: Ib04008cd88fc38ce8cf83cfecd52e3ebe6ff921a
2021-12-01 01:37:17 +00:00
Treehugger Robot
9118768352 Merge "Define $(PRODUCT_OUT) before running the board config" 2021-12-01 01:15:53 +00:00
Treehugger Robot
68a38e8e95 Merge "Embed zucchini version info in target_files" am: a9bc0e1db5
Original change: https://android-review.googlesource.com/c/platform/build/+/1906834

Change-Id: I448ed55d3ae30bcadc64893753330ce5f19d0fbe
2021-11-30 23:57:42 +00:00
Cole Faust
29bb6132c8 Strip more board config variables
These variables' values show up in the command line
of certain build commands, so they need to be stable
to have stable ninja files.

The starlark board configuration strips these variables,
causing a discrepency between the starlark and make
versions of board configuration.

Bug: 201700692
Test: ./build/bazel/ci/rbc_regression_test.sh beagle_x15-userdebug
Change-Id: Id053435409821a3fe5997c07610ef835e0c83112
2021-11-30 14:00:57 -08:00
Colin Cross
143af9284f Remove duplicate includes of BUILD_NOTICE_FILE
Some module types include BUILD_NOTICE_FILE a second time after
the include from base_rules.mk.  This won't work after a future
change, and doesn't seem to be necessary as none of the files
leave any modified LOCAL* variables in place for notice_files.mk
to read.

Bug: 207445310
Test: m checkbuild
Change-Id: I8c68888d6bf26926f5c2216abe147ccf28ddc2b8
2021-11-30 13:20:01 -08:00
Colin Cross
fa4dece05a Merge "Make SOONG_HOST_OUT an alias for HOST_OUT" am: 6013329bff
Original change: https://android-review.googlesource.com/c/platform/build/+/1897199

Change-Id: If74d1933ed080729c69de2fe2f76283102dab413
2021-11-30 20:47:12 +00:00
Kelvin Zhang
c06f0627c3 Embed zucchini version info in target_files
external/zucchini/version_info.h contains version info for zucchini
diffing algorithm. OTA tools will use these version info to check for
compatibility and determine if zucchini can be used safely. Owners of
zucchini agreed to keep the format of version_info.h stable so it's
parser friendly.

Bug: 194237829
Test: m dist
Change-Id: If8e37533933b346d3f03adab9263679910ab328c
2021-11-30 12:38:39 -08:00
Colin Cross
6013329bff Merge "Make SOONG_HOST_OUT an alias for HOST_OUT" 2021-11-30 20:31:26 +00:00
Cole Faust
52e5d9c776 Define $(PRODUCT_OUT) before running the board config
Certain board configurations reference $(PRODUCT_OUT)
through deferred expansion, which will no longer work
after conversion to starlark.

Bug: 201700692
Test: build/bazel/ci/rbc_regression_test.sh -b yukawa-userdebug
Change-Id: I02055f5c4a05e540c1752d5964d4db4306292c3b
2021-11-30 11:24:33 -08:00
Jiakai Zhang
44ffb21e53 Add a variable to specify standalone system server jars.
This is the list of jars that system_server loads dynamically using
separate classloaders. We will rely on this variable to decide which
jars to preopt in the build system and on the device for system_server.

The list is supposed to be in sync with the code in SystemServer.java.
There will be a follow-up CL to add a comment in SystemServer.java to
remind developers to keep them in sync.

Bug: 203198541
Test: m nothing
Change-Id: I305a73218ef2d2c61ac3795d21026b2afe7007fd
2021-11-30 11:07:37 +00:00
Inseob Kim
e124e3a02d Add 32.0 to PLATFORM_SEPOLICY_COMPAT_VERSIONS
Bug: 206330997
Test: m selinux_policy
Change-Id: Ibbe71843a0ba5677203eabb27690562d55cb057e
2021-11-30 13:44:52 +09:00
Ulyana Trafimovich
b128e28695 Merge "Sort PRODUCT_APEX_BOOT_JARS automatically." am: af78df0553
Original change: https://android-review.googlesource.com/c/platform/build/+/1903170

Change-Id: I82cebfc087ff033f7852c0550fb4568640493021
2021-11-29 12:04:30 +00:00
Ulyana Trafimovich
af78df0553 Merge "Sort PRODUCT_APEX_BOOT_JARS automatically." 2021-11-29 11:46:54 +00:00
Inseob Kim
a6568e00e2 Remove 26.0 and 27.0 compat support
Treble doesn't support T system + O vendor, so removing 26.0 (N) and
27.0 (O) prebuilts and compat files.

Bug: 207815515
Test: build
Change-Id: Ie12737cc5ca8725caf834d9bf1bdfe840ac516c0
2021-11-29 01:29:28 +00:00
Ulya Trafimovich
c9ec59c72a Sort PRODUCT_APEX_BOOT_JARS automatically.
This is a follow-up CL for https://r.android.com/1900565.

This is needed because product makefiles may need to add their own
APEX boot jars, and they cannot insert them in the correct alphabetical
order on the list. So it needs to be sorted automatically. Do this
after processing all product makefiles and populating the variable,
but before passing it to Soong.

Bug: 207474880
Test: lunch aosp_cf_x86_64_phone-userdebug && launch_cvd
      # cuttlefish device boots successfully
Change-Id: I86b58ef8aeac595e401d872f59a2936a67bedeec
2021-11-26 16:02:54 +00:00
Cole Faust
638472caa8 Merge "Change type of TARGET_BUILD_APPS from bool to list" am: 7d9103b390
Original change: https://android-review.googlesource.com/c/platform/build/+/1900878

Change-Id: Ib21e3dc644b5930403dd42c7a47a01b916cb918b
2021-11-25 01:27:02 +00:00
Cole Faust
7d9103b390 Merge "Change type of TARGET_BUILD_APPS from bool to list" 2021-11-25 01:06:53 +00:00
Android Build Coastguard Worker
8e08f1dfcd Make change and version bump to SQ1A.220105.001
Change-Id: I60f2a06050b58b92104e01f7162beb4adcfb9e0b
2021-11-24 23:26:38 +00:00
Paul Scovanner
e04aaf2f4c [DO NOT MERGE]
Update Security String to 2022-01-05

Bug: 207022948
Change-Id: Ie4afce5ae2b2a1b60fb0fc78ea014d220e08a981
(cherry picked from commit 9e20227ea5)
Merged-In:Ie4afce5ae2b2a1b60fb0fc78ea014d220e08a981
2021-11-24 23:20:37 +00:00
Treehugger Robot
2694a33cb6 Merge "Exclude predefined variables from board config" am: 359665674f
Original change: https://android-review.googlesource.com/c/platform/build/+/1900875

Change-Id: If9850339861ea48042a2c397294303430efac819
2021-11-24 20:48:28 +00:00
Treehugger Robot
359665674f Merge "Exclude predefined variables from board config" 2021-11-24 20:30:00 +00:00
Treehugger Robot
3f8601901a Merge "Sort PRODUCT_APEX_SYSTEM_SERVER_JARS automatically." am: 03aa6cd538
Original change: https://android-review.googlesource.com/c/platform/build/+/1900565

Change-Id: I0ec4ccb90656eb52aca495a4da7ba64c033418df
2021-11-24 19:34:15 +00:00
Ulya Trafimovich
00496c1683 Sort PRODUCT_APEX_SYSTEM_SERVER_JARS automatically.
This is needed because product makefiles may need to add their own
system server jars to this variable, and they cannot insert them in
the correct alphabetical order on the list. So it needs to be sorted
automatically. Do this after processing all product makefiles and
populating the variable, but before passing it to Soong.

Bug: 207474880
Test: atest art_standalone_dexpreopt_tests:art_standalone_dexpreopt_tests.DexpreoptTest#ForSystemServer
Change-Id: I80dbf555c395c92539c506d3d8b1f2f101a58bce
2021-11-24 15:41:49 +00:00
Treehugger Robot
9680501cc8 Merge "DO NOT MERGE: Revert "Add NEED_AIDL_NDK_PLATFORM_BACKEND"" 2021-11-24 05:35:08 +00:00
Nahian Ashraf
f41bff99b3 DO NOT MERGE: Revert "Add NEED_AIDL_NDK_PLATFORM_BACKEND"
Revert submission 1859096-remove_ndk_platform

Reason for revert: Build Breakage
Reverted Changes:
I62c995642:Add NEED_AIDL_NDK_PLATFORM_BACKEND
I1cbdce916:Don't generate the ndk_platform backend unless exp...

Change-Id: I4ddfb73ed7b9bcf1c6dee113e3ba9fd66d79d296
2021-11-24 03:34:07 +00:00
Cole Faust
5588a88969 Change type of TARGET_BUILD_APPS from bool to list
TARGET_BUILD_APPS is supposed to be a list of apps to
build, so having it be a bool was incorrect. Change it
to properly reflect what it is, because the starlark
product configuration relies on soong's interpretation
of variables types.

Bug: 201700692
Test: Presubmits
Change-Id: I00109b57abbcda86077f0465f982f54b4a77a7f0
2021-11-23 19:04:11 -08:00
Jiyong Park
c28911dd2a Merge "Add NEED_AIDL_NDK_PLATFORM_BACKEND" am: 4d7ddff334
Original change: https://android-review.googlesource.com/c/platform/build/+/1867788

Change-Id: I4c3fdafa50465bd050dbf3ef9e873e0e9fb0ff7c
2021-11-24 02:00:55 +00:00
Jiyong Park
4d7ddff334 Merge "Add NEED_AIDL_NDK_PLATFORM_BACKEND" 2021-11-24 01:43:19 +00:00
Cole Faust
be6d5f13b2 Exclude predefined variables from board config
mk2rbc has a few predefined variables that can't be
set in the product/board config makefiles, unless they're
set to their predefined values. Exclude these variables
from the board config input variables so that they don't
conflict.

Bug: 201700692
Test: m RBC_BOARD_CONFIG=1 mainline_system_x86_64-userdebug (ninja files differ still but this fixes a compilation error)
Change-Id: Idc11b2c5029d28116236b289ad1f09afaaf83cc3
2021-11-23 16:45:29 -08:00
Cole Faust
390d1e0795 Merge "Return product config variables from board_configuration" am: 4228f8f7a3
Original change: https://android-review.googlesource.com/c/platform/build/+/1900113

Change-Id: I36ebee83203c28d40498ca85935b662e222f317a
2021-11-23 21:04:27 +00:00
Cole Faust
4228f8f7a3 Merge "Return product config variables from board_configuration" 2021-11-23 20:46:45 +00:00
Treehugger Robot
871500d4b6 Merge "Disallow setting LOCAL_MODULE_STEM for android packages" am: 55870dd500
Original change: https://android-review.googlesource.com/c/platform/build/+/1880753

Change-Id: I60ebc76a554355e48e0ee6b6d3d3a716ed842b3d
2021-11-23 05:36:16 +00:00
Treehugger Robot
55870dd500 Merge "Disallow setting LOCAL_MODULE_STEM for android packages" 2021-11-23 05:21:15 +00:00
Cole Faust
f0d7d8ff73 Return product config variables from board_configuration
The board config can actually change a few product config
variables that are not made read-only.

Bug: 201700692
Test: ./build/bazel/ci/rbc_regression_test.sh -b aosp_cf_x86_64_phone
Change-Id: Ib2ac04ac2c5a56d32bca51fc8189e44e180075ee
2021-11-22 16:31:46 -08:00
Martin Stjernholm
382d8ae9c4 Merge "Configure boot image profiles for platform and unbundled ART module builds (reland)." am: f823ec6e99
Original change: https://android-review.googlesource.com/c/platform/build/+/1896660

Change-Id: I4f7a2e3c953e65d756f2eec9d7afdc033187682c
2021-11-22 14:24:16 +00:00
Martin Stjernholm
91964c82e3 Configure boot image profiles for platform and unbundled ART module
builds (reland).

- Use art/build/boot/boot-image-profile.txt for the primary boot image
  in the ART module, both when it's built from source in platform and
  as an unbundled module.

- Use frameworks/base/boot/boot-image-profile.txt for the framework
  extension image in platform, but not in unbundled builds.

This should obsolete the combined profile
frameworks/base/config/boot-image-profile.txt.

This relands https://r.android.com/1881863 with a fix to allow multiple
values on PRODUCT_DEX_PREOPT_BOOT_IMAGE_PROFILE_LOCATION.

Test: build/soong/soong_ui.bash --dumpvar-mode \
        PRODUCT_DEX_PREOPT_BOOT_IMAGE_PROFILE_LOCATION
  and check that it prints both art/build/boot/boot-image-profile.txt
  and frameworks/base/boot/boot-image-profile.txt in a platform build
  on master.
Test: build/soong/soong_ui.bash --dumpvar-mode \
        PRODUCT_DEX_PREOPT_BOOT_IMAGE_PROFILE_LOCATION
  and check that it prints only art/build/boot/boot-image-profile.txt
  in an unbundled build on master-art.
Test: banchan com.android.art && m
  on master-art and check that
  out/soong/.intermediates/art/build/apex/com.android.art/android_common_com.android.art_image/image.apex/javalib/x86_64/boot.oat
  shrinks from 14 MB to 4.7.
Test: m droid
  on master together with https://r.android.com/1895131 and check that
  out/soong/.intermediates/art/build/apex/com.android.art/android_common_com.android.art_image/image.apex/javalib/x86_64/boot.oat
  and out/target/product/vsoc_x86_64/system/framework/x86_64/boot-framework.oat
  are identical.
Test: lunch armv8-eng && art/tools/buildbot-build.sh
  on master-art
Bug: 174746397
Change-Id: I9114271bc69cf0888150b2c778a086bc50b73045
2021-11-19 16:21:37 +00:00
Treehugger Robot
f15629526d Merge "Update conversion results file only when it changed." am: 9a991fab04
Original change: https://android-review.googlesource.com/c/platform/build/+/1896415

Change-Id: Ic198132d5816ffd0e33bf07f6c9116fa8618e0e8
2021-11-19 03:32:11 +00:00
Treehugger Robot
9a991fab04 Merge "Update conversion results file only when it changed." 2021-11-19 03:12:12 +00:00
Colin Cross
013b1ee778 Merge "Extract primary APK from apk sets in Soong" am: 345da983ad
Original change: https://android-review.googlesource.com/c/platform/build/+/1893500

Change-Id: Ib27dd9280f1aeabe0ba1f201518b0a8db06f0215
2021-11-19 02:33:56 +00:00
Colin Cross
345da983ad Merge "Extract primary APK from apk sets in Soong" 2021-11-19 02:18:20 +00:00
Colin Cross
da166c5ad4 Make SOONG_HOST_OUT an alias for HOST_OUT
Soong now installs to the same directory as Make, point SOONG_HOST_OUT
at HOST_OUT.

Bug: 204136549
Test: m checkbuild
Change-Id: I49bfc0466056d270c8023288a6fe778c3445a900
2021-11-18 16:26:58 -08:00
Sasha Smundak
7dc8f486c2 Update conversion results file only when it changed.
Test: treehugger
Change-Id: Ia0d6bf614fa0714a977b2880f7271d54df034366
2021-11-18 15:17:59 -08:00
Treehugger Robot
2d04577ee7 Merge changes from topics "dist_for_goals", "mk2star" am: 613ae210f6
Original change: https://android-review.googlesource.com/c/platform/build/+/1890801

Change-Id: I9dbe243c6941b04fe8262e59c072fa6a2839d0e2
2021-11-18 22:23:49 +00:00
Xin Li
0d8b812568 Merge "Merge sc-qpr1-dev-plus-aosp-without-vendor@7810918" into stage-aosp-master 2021-11-18 21:28:37 +00:00
Sasha Smundak
c20dd972a9 Runtime reporting of the conversion errors.
Bug: 204062171
Test: rbcrun build/make/tests/conversion_error.rbc (displays a message, stops)
  rbcrun RBC_MK2RBC_CONTINUE=t build/make/tests/conversion_error.rbc  (displays a message and continues)
Change-Id: Idf0fe6bbb08b1eca1f392d81950eed4a214f3289
2021-11-18 11:27:55 -08:00
Sasha Smundak
91fc734100 Runtime support for dist-for-goals.
Convert dist-for-goals.

Bug: 198496782
Test: rbcrun build/make/tests/run.rbc
Change-Id: I46ef9e897143aecf8bd28ad8569d48e74530b0e5
2021-11-18 11:20:34 -08:00
Yifan Hong
c59eeaa272 Add recovery service_contexts. am: 276b8c0230
Original change: https://android-review.googlesource.com/c/platform/build/+/1891251

Change-Id: Ic397dc0036431b9bdb90ffbd2ba80f32288e1a6c
2021-11-18 05:01:37 +00:00
Yifan Hong
351cd2e489 Merge changes from topic "servicemanager-recovery"
* changes:
  Add servicemanager.recovery to base_vendor.mk.
  Add recovery service_contexts.
2021-11-18 04:39:14 +00:00
Colin Cross
f42c7d6be1 Extract primary APK from apk sets in Soong
In preparation for Soong handling the installation rules, extract
the primary APK from the apk set in Soong.

Bug: 204136549
Test: build test android_app_set
Change-Id: I416b57009101ca4c05c11102f260e102af13bf0d
2021-11-17 19:45:49 -08:00
Treehugger Robot
dacbe7a5a2 Merge "Add notdir implementation" 2021-11-17 20:58:24 +00:00
Cole Faust
0cc94d3275 Add notdir implementation
mk2rbc would already translate notdir calls,
but since there was no implementation it would
fail at runtime.

Bug: 201700692
Test: m rbcrun; rbcrun build/make/tests/run.rbc
Change-Id: Ie0f4e7b65448e612fa56f87b0bc138648cc0ad58
2021-11-17 10:50:14 -08:00
Android Build Coastguard Worker
8dc106e599 Version bump to SQ1A.211205.010 [core/build_id.mk]
Change-Id: I5a87dd2cefcfd7d6b46f5b1c536ab06b53a454c8
2021-11-17 18:23:35 +00:00
Cole Faust
8a7e9afc54 Merge "Don't assume _soong_config_namespaces_key is present" 2021-11-16 19:45:20 +00:00
Android Build Coastguard Worker
314b562dc0 Version bump to SQ1A.211205.009 [core/build_id.mk]
Change-Id: I526237e29ba83c5f2dc366912d2ee6ce51235d9a
2021-11-16 08:28:12 +00:00
Cole Faust
2f4692bf31 Don't assume _soong_config_namespaces_key is present
The board configuration doesn't use init_globals(),
which is where _soong_config_namespaces_key normally
is set. Just assume empty dictionaries in
soong_config_namespace where appropriate.

Bug: 201700692
Test: build/bazel/ci/rbc_product_config.sh -b armv8-userdebug
Change-Id: I5f1e52fa0bdde32bff0e8db54861557dcb327190
2021-11-15 16:03:51 -08:00
Colin Cross
d1c2c4e1b8 Merge "Translate BUILT_INSTALLED to LOCAL_BUILT_MODULE" 2021-11-15 23:57:57 +00:00
Xin Li
b461e822a1 Merge sc-qpr1-dev-plus-aosp-without-vendor@7810918
Bug: 205056467
Merged-In: I42fd618b5a018abd57e6eab4fe4ed6ba9f70a235
Change-Id: I5e0d686c2a1cc15e6a3115243f3a83cb070b111c
2021-11-15 23:30:54 +00:00
Treehugger Robot
f1e1bcb0ee Merge "Always default to 1.9 for host java modules in Android.mk files" 2021-11-15 22:36:51 +00:00
Colin Cross
362f55af96 Always default to 1.9 for host java modules in Android.mk files
Host modules shouldn't use the logic for device modules to determine
the java language version to use, always default to 1.9.

Bug: 202761304
Test: m checkbuild
Change-Id: I268dd34d887db4646e188858c7f2aedc30966856
2021-11-15 21:46:52 +00:00
Colin Cross
802f2116ed Translate BUILT_INSTALLED to LOCAL_BUILT_MODULE
Soong creates install rules and lists them in LOCAL_SOONG_INSTALL_PAIRS,
where they get copied to ALL_MODULE.$(m).BUILT_INSTALLED.  BUILT_INSTALLED
is used by package-modules.mk to copy the built modules to alternate
install locations for building zips like continuous_native_tests.zip.

Translate Soong's built module location, which is listed in
LOCAL_PREBUILT_MODULE_FILE, into $(LOCAL_BUILT_MODULE) when setting
BUILT_INSTALLED so that package-modules.mk copies from
$(LOCAL_BUILT_MODULE) instead of $(LOCAL_PREBUILT_MODULE_FILE).  This
ensures that the transitive dependencies added to $(LOCAL_BUILT_MODULE),
for example the unstripped symbols files, are present when
continuous_native_tests.zip is built.

Bug: 206137439
Test: manual
Change-Id: I1a45cd6d3c81d6435a10f4d29557e521753068a4
2021-11-15 13:15:22 -08:00
Inseob Kim
c1d4512e02 Add missing apksigner dependency
Test: build after removing apksigner
Change-Id: I1ed7f13395bf7d5fe5f06a6bc3280809b5038636
2021-11-15 11:26:57 +09:00
Yifan Hong
276b8c0230 Add recovery service_contexts.
This allows servicemanager to run in recovery.

Test: manual
Bug: 170338625
Change-Id: I60671af0bcaf13fd545b2f286243fee474caace5
2021-11-13 00:28:05 -08:00
Ivan Lozano
d96be59972 Merge soong_{cc,rust}_prebuilt.mk
Much of soong_cc_prebuilt.mk is duplicated in soong_rust_prebuilt.mk.
This adds maintenance burden and increases the risk of bugs or
inconsistencies. Merge the two to simplify this.

Bug: N/A, clean-up
Test: m
Change-Id: I833fba94e299006b34f8e53d5519c6b19f684d39
2021-11-12 13:20:08 -05:00
Inseob Kim
f69346e0a8 Add fsverity digest manifest
fsverity digest manifest stores a map from files to fsverity digests.
The manifest is installed as a serialized protobuf file, to a signed apk
system/etc/security/fsverity/BuildManifest.apk.

Bug: 193113311
Test: build with PRODUCT_SYSTEM_FSVERITY_GENERATE_METADATA := true
Change-Id: I55fc10400206b8ce0d5f198faea08fe3930b362c
2021-11-11 11:19:44 +00:00
Inseob Kim
9cda397948 Implement fsverity metadata generator
Using fsverity tool, fsverity metadata for specific artifacts in system
mage can be generated. Users can do that by setting a makefile variable
PRODUCT_SYSTEM_FSVERITY_GENERATE_METADATA to true.

If set to true, the following artifacts will be signed.

- system/framework/*.jar
- system/framework/oat/<arch>/*.{oat,vdex,art}
- system/etc/boot-image.prof
- system/etc/dirty-image-objects

One fsverity metadata container file per one input file will be
generated in system.img, with a suffix ".fsv_meta". e.g. a container
file for "system/framework/foo.jar" will be
"system/framework/foo.jar.fsv_meta".

Bug: 193113311
Test: build with PRODUCT_SYSTEM_FSVERITY_GENERATE_METADATA := true
Change-Id: Ib70d591a72d23286b5debcb05fbad799dfd79b94
2021-11-11 17:30:19 +09:00
Treehugger Robot
372d74a8c9 Merge "Record ALL_DEPS by default." 2021-11-11 04:48:16 +00:00
Eric Miao
6f2d435d8d Merge "Add oatdump and dexdump to dexpreopt_tools.zip" 2021-11-11 04:30:27 +00:00
Jim Tang
5c6410edee Record ALL_DEPS by default.
Abandon the use of RECORD_ALL_DEPS to record ALL_DEPS.

BUG: 204397180

Test: m, and inspect module-info.json.
Change-Id: Iaf35580b52c11ad37017b1fb8e0937b859d3f55b
2021-11-11 10:24:51 +08:00
Treehugger Robot
7bd2d13cde Merge "Fix BOARD_SYSTEMSDK_VERSIONS checks" 2021-11-10 23:38:28 +00:00
Cole Faust
e856367da1 Merge "Add soong_config_get" 2021-11-10 19:46:48 +00:00
Treehugger Robot
585ec03c47 Merge changes from topic "soong-java-install"
* changes:
  Move java install rules into Soong
  Don't create compatibility suite copy rules for installed path
2021-11-10 17:05:51 +00:00
Anton Hansson
0e21221d30 Merge "Fix product single value variables failed issue" 2021-11-10 16:45:36 +00:00
Cole Faust
70a886c7ce Add soong_config_get
Having a function to get soong config variables
makes it easier to convert to starlark.

Bug: 201700692
Test: m RBC_PRODUCT_CONFIG=1 RBC_BOARD_CONFIG=1 nothing and check output files
Change-Id: I8627555df10d3f66f6154c00be9f0565076f1f94
2021-11-09 17:09:04 -08:00
Justin Yun
e81ec6960a Fix BOARD_SYSTEMSDK_VERSIONS checks
BOARD_SYSTEMSDK_VERSIONS must be greater than or equal to the minimum
of PRODUCT_SHIPPING_API_LEVEL and BOARD_API_LEVEL. If BOARD_API_LEVEL
is not defined, read BOARD_SHIPPING_API_LEVEL. If both board api
levels are not defined, compare only with PRODUCT_SHIPPING_API_LEVEL.

Bug: 204964200
Bug: 201489975
Bug: 202919753
Test: manual test with different settings
Change-Id: I36fa0b2fed3bca9ebe1baad46ee1dbe8cb1414e3
2021-11-10 00:34:17 +00:00
Eric Miao
1d0fd2cb91 Add oatdump and dexdump to dexpreopt_tools.zip
Change-Id: If7615e1da24bcb819f595adb88060b164499a598
2021-11-09 18:53:39 +00:00
liulvping
689c3fb5d7 Fix product single value variables failed issue
Test: source & lunch & make

Signed-off-by: liulvping <liulvping@xiaomi.com>
Change-Id: Idd0e1c561504afb7c7fef4242b3b122cba220ed0
2021-11-09 02:05:25 +00:00
Colin Cross
47cfffea79 Move java install rules into Soong
Remove the copy rules for LOCAL_SOONG_BUILT_INSTALLED, they will already
be created by Soong.

Also clean the soong host tools directory to remove any old copies of
java binaries.

Bug: 204136549
Test: m checkbuild
Change-Id: Ib6b5362ad59aa48770e48541430d6857846926c2
2021-11-08 15:23:32 -08:00
Colin Cross
a69b809425 Don't create compatibility suite copy rules for installed path
Don't create compatibility suite copy rules for $(LOCAL_BUILT_MODULE)
to $(LOCAL_INSTALLED_MODULE), as that could conflict with a Soong
install rule.  Instead, always create the install rule the normal way,
and replace the compatibility suite copy rule with a noop if it is the
same as the normal rule.

Bug: 204136549
Test: m checkbuild
Change-Id: Ic8ac80eda8554fae2b7ecc2516165da020bdaebe
2021-11-08 15:23:32 -08:00
Colin Cross
d954ea888a Add missing dependency from module name to symlinks
The rules to install the symlinks had dependencies from PRODUCT_PACKAGES
install rules, but from manual install requests like `m toybox`.  Add
the missing dependencies.  Also add the new declare-0p-target licensing
call.

Fixes: 205524422
Test: m toybox
Change-Id: Ie9a5e37b09250aa271ab153a13f41bc34fa4a38a
2021-11-08 19:40:22 +00:00
Anton Hansson
db7732900b Merge "Do not disable prebuilts for sdk builds" 2021-11-08 10:27:22 +00:00
Cole Faust
c2becd087a Disallow setting LOCAL_MODULE_STEM for android packages
LOCAL_MODULE_STEM is not used in the packaging code,
except when setting PACKAGES.$(LOCAL_MODULE).STEM.
Having this disconnect between PACKAGES.$(LOCAL_MODULE).STEM
and the actual name of the apk causes an apk signing
step to fail.

Other module types like BUILD_HEADER_LIBRARY explicetly
disallow setting LOCAL_MODULE_STEM, so we can also just
do that for packages.

Fixes: 204027319
Test: Presubmits
Change-Id: Ib3da9a8dd6792a6c9d725cb24b835b32dbb13c40
2021-11-05 12:35:18 -07:00
Cole Faust
2f1bd70c9c Merge "Make starlark board configuration work with sdk_phone_x86_64" 2021-11-05 18:42:12 +00:00
Android Build Coastguard Worker
32ce1a4113 Version bump to SQ1A.211205.008 [core/build_id.mk]
Change-Id: I701608290fb184cabcc82c26a7fe841f514d5b4b
2021-11-05 17:31:39 +00:00
Colin Cross
11b78c16ad Merge "Move tools compiled by Soong to HOST_OUT_EXECUTABLES" 2021-11-05 17:14:59 +00:00
Anton Hansson
30ae089556 Do not disable prebuilts for sdk builds
The artifacts in the SDK zip should be OK to build with a prebuilt
stubs enabled, even if prebuilt apexes are not, because the system
images in the SDK stub are not currently used.

Bug: 205008975
Bug: 204407658
Test: m sdk
Change-Id: Ia78cf87743ff394dcfaa1b43556b230c0dda8742
2021-11-05 16:34:27 +00:00
Cole Faust
985fa48a98 Make starlark board configuration work with sdk_phone_x86_64
The main issue with board configuration up till this
cl was that it didn't have access to the product configuration
variables. Pass those in by dumping the make variables to a
temporary file, which is then converted to RBC, loaded,
and passed to the starlark board config..

Bug: 201700692
Test: build/bazel/ci/rbc_product_config.sh -pb sdk_phone_x86_64-userdebug
Change-Id: I9a4946b970ca43c5b5f53a6c507ad2c1a2eca61e
2021-11-04 16:13:24 -07:00
Steven Moreland
ec71cbf0c8 Merge "vintf recovery install parity w/ init_rc" 2021-11-04 22:28:51 +00:00
Treehugger Robot
cd128891ed Merge changes from topic "tproto"
* changes:
  Convert .meta_lic files to textproto
  Add macros for non-module license metadata and deps
2021-11-03 18:31:02 +00:00
Colin Cross
1ee26cae73 Convert .meta_lic files to textproto
Make it easier to write tools against .meta_lic files and store complex
data by writing them in textproto.

Test: builds
Change-Id: Ibbb6cfbb1bdddd3d938a86d563673a049d826d66
2021-11-03 15:44:00 +00:00