Commit graph

83094 commits

Author SHA1 Message Date
Zi Wang
4873775c9f Merge "Use OutputFilesProvider on syspropJavaGenRule" into main am: d156fee224
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3125338

Change-Id: I3f032438be2987dbdf7fa2d3d85278d00a44055f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-14 00:20:09 +00:00
Zi Wang
d156fee224 Merge "Use OutputFilesProvider on syspropJavaGenRule" into main 2024-06-14 00:16:50 +00:00
Treehugger Robot
aac618bb2d Merge "Properly track where a build flag is declared" into main am: 5078551e97
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3132914

Change-Id: I661af7b1cdcabe87b0d71b0113cd2087823ccc10
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-14 00:04:36 +00:00
Treehugger Robot
5078551e97 Merge "Properly track where a build flag is declared" into main 2024-06-14 00:02:05 +00:00
Treehugger Robot
55fa55c62e Merge "Add following directories to Android.mk denylist to block new Android.mk files." into main am: 1571ad9605
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3126355

Change-Id: Ib5c59c4e6d5f2b650fbb41eb49973520e634d4f7
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 23:49:25 +00:00
Treehugger Robot
1571ad9605 Merge "Add following directories to Android.mk denylist to block new Android.mk files." into main 2024-06-13 23:43:25 +00:00
Treehugger Robot
cbcabf569c Merge "Modify the installation rules of sh binary based on the image variants" into main am: 6c76ad374e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3125655

Change-Id: Ia0455f4b15aa86bef47722e15d123642376bdc7b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 22:57:27 +00:00
Treehugger Robot
6c76ad374e Merge "Modify the installation rules of sh binary based on the image variants" into main 2024-06-13 22:52:03 +00:00
LaMont Jones
97e29a9cb4 Properly track where a build flag is declared
This allows us to generate an error when it is then set in an earlier
location in the list.

Bug: 346883187
Test: manual
Change-Id: I1c8389ff0d5a16c080008967ab5e0b9b93101301
2024-06-13 15:49:29 -07:00
Treehugger Robot
0adcd9aefa Merge "Call PackageFile for dexpreopt files of APEX bundles." into main am: 9034af498e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3128073

Change-Id: I40cce87cc466de96df45e05c9a6cf7b073725ec8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 21:49:51 +00:00
Jihoon Kang
71825167e0 Modify the installation rules of sh binary based on the image variants
This change modifes the build rules of sh binary module type so that:
- The installation paths respects the image variations and the
  *_available properties.
- The androidmk entries have subnames so that the names of the different
  variants do not collide.

Test: Patch ag/27004177 and run m nothing
Bug: 336582138
Change-Id: Id85c428980ab459bff8d84098bd6c501a12231ed
2024-06-13 21:49:47 +00:00
Treehugger Robot
9034af498e Merge "Call PackageFile for dexpreopt files of APEX bundles." into main 2024-06-13 21:46:03 +00:00
mrziwang
ba2a460008 Use OutputFilesProvider on syspropJavaGenRule
In the context of incremental soong, the output files
inter-module-communication will be through OutputFilesProvider.
The OutputFileProducer interface will be deprecated.

Test: CI
Bug: 339477385
Change-Id: I3b1cb3a4cfafa1385ef27a427009abb13accf834
2024-06-13 14:16:52 -07:00
Zi Wang
3581dc9734 Merge "Use OutputFilesProvider on prebuilt_etc" into main am: afc28427cf
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3125335

Change-Id: Ideac73b3f2784718a0787a604fca6684dba31f67
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 21:04:23 +00:00
Zi Wang
afc28427cf Merge "Use OutputFilesProvider on prebuilt_etc" into main 2024-06-13 20:56:57 +00:00
Treehugger Robot
220d0340fb Merge "Remove timestamp from local build number" into main am: 68f5fbf99b
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3131837

Change-Id: I5ba8743ad87e9ed2ef6a010104ff37385fcecdad
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 18:49:36 +00:00
Treehugger Robot
68f5fbf99b Merge "Remove timestamp from local build number" into main 2024-06-13 18:45:09 +00:00
Cole Faust
1ae7b774eb Remove timestamp from local build number
The build_info.prop file was converted to soong, which then caused it to
have a stale build number due to not adding the build number file as a
dependency to avoid rebuilds. I added it as a dependency to fix the
staleness, but it always rebuilds locally now.

I think the way it worked before, it would get stale build numbers,
except that it was cleared with installclean which was always run on CI.
Now that it's a soong module and generated in out/soong/.intermediates
it's not cleared by installclean. I could make a system to register
files that should be installclean'd from a soong module, but I'd
eventually like to eliminate the need to run installclean entirely.

So as an alternative, just make the build number not change every build
when doing local builds, by removing the timestamp from it.

Bug: 346757289
Test: m repeatedly and observe no rebuilds the second time (of the system image, the build flags infrastructure seems to do some small rebuilding)
Change-Id: I0207feb739523dde3e89d1e5c4822865f641c313
2024-06-13 10:27:20 -07:00
Justin Yun
613bdc5b64 Call PackageFile for dexpreopt files of APEX bundles.
Soong generates AndroidMk modules and Make installs the required
dexpreopt files for APEX bundles. This dependency is not tracked by
the soong and missing from the soong filesystem.
Call PackageFile for the dexpreopt files of APEX bundles to install
the files in the soong-built system image.

Bug: 346439786
Test: lunch aosp_cf_x86_64_phone-trunk_staging-userdebug \
      && m aosp_cf_system_x86_64
Change-Id: I6af4afe5b3183c89bf687ac779007b87e1d7e948
2024-06-13 12:37:04 +09:00
Justin Yun
e024ec0ba1 Call PackageFile for dexpreopt files am: 22c8aca893
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3110884

Change-Id: I0ecc092ec4dacfd90b67ccdd0d213021c951d2c6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-13 02:36:00 +00:00
Justin Yun
22c8aca893 Call PackageFile for dexpreopt files
Dexpreopt files use RuleBuilder.Install() that installs the file from
Make. By calling PackageFile, this information is also shared to
soong PackagingSpec.

Bug: 339314890
Test: See if .prof, .bprof, and vdex files are installed with
      "m aosp_cf_system_x86_64"

Change-Id: I42167603ecfd4334e4f35602bdf03a21846fc798
2024-06-13 09:04:42 +09:00
Treehugger Robot
bbdc4a9f7f Merge "Add unit test to verify contents of bootclasspath.pb.textproto" into main am: 6918e6084c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3129153

Change-Id: I693e912de11886be40a23957be787433f88e0ea7
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 22:52:55 +00:00
Spandan Das
02ff4f972f Remove unused dexpreopt install path function am: 8a296baab8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3128899

Change-Id: Ief5bdd7f8651d4a6850c46f5194ae5fc68da8c61
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 22:52:42 +00:00
Treehugger Robot
6918e6084c Merge "Add unit test to verify contents of bootclasspath.pb.textproto" into main 2024-06-12 22:51:23 +00:00
Spandan Das
8a296baab8 Remove unused dexpreopt install path function
`odexOnSystemOther` (presumably) returns a boolean indicating whether
.odex/.vdex files should be installed in system_other.img. The
installation location logic is now colocated in build/soong/dexpreopt
package, so we can delete this unused function.

Test: go build ./java
Change-Id: Ibd1a3a0b945f8d7953baad05cbaf65cb58b5a05a
2024-06-12 21:17:29 +00:00
Wei Li
8778d26c9d Add following directories to Android.mk denylist to block new Android.mk files.
bionic/
development/
device/sample/
prebuilts/
sdk/
test/
trusty/

Bug: 318428689
Change-Id: I327bf354df064a5249edc3e9c846199cde0ce00b
Test: CIs
2024-06-12 21:13:24 +00:00
Spandan Das
7e14b86de1 Merge "Fix missing missing (min|max)_sdk_version in bootclasspath.pb" into main am: a551b011d0
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3128893

Change-Id: I53df669f35a362252af9825b9f9b37ed09b0e982
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 18:52:33 +00:00
Spandan Das
fcea0a8cc4 Add unit test to verify contents of bootclasspath.pb.textproto
The unit test is useful for verifying that
min_sdk_version/max_sdk_version information is populated correctly.
Followup to https://r.android.com/3128893

Bug: 345621958
Test: go test ./apex
Change-Id: Id7696a8cefaab6d0b7f38b65a33e326152ac12d3
2024-06-12 18:22:46 +00:00
Spandan Das
a551b011d0 Merge "Fix missing missing (min|max)_sdk_version in bootclasspath.pb" into main 2024-06-12 18:21:33 +00:00
Spandan Das
306804fe41 Fix missing missing (min|max)_sdk_version in bootclasspath.pb
bootclasspath.pb.textproto of an apex contains
min_sdk_version/max_sdk_version information of its exported libraries.
It is populated using the stateful minSdkVersion/maxSdkVersion
properties of the SdkLibrary module. These were previously indirectly
populated by invoking `module.Library.GenerateAndroidBuildActions(ctx)`,
which has been removed https://r.android.com/3079425.

This CL updates the implementation to use `MinSdkVersion(ctx)` and
`MaxSdkVersion(ctx)` to get the appropriate values directly and not rely
on GenerateAndroidBuildActions.

Bug: 345621958
Test: cat out/soong/.intermediates/packages/providers/MediaProvider/apex/com.android.mediaprovider-bootclasspath-fragment/android_common_apex30/c49cac19acc21350e0f3590de64d2f7f/bootclasspath.pb.textproto
jars {
path: "/apex/com.android.mediaprovider/javalib/framework-mediaprovider.jar"
classpath: BOOTCLASSPATH
min_sdk_version: "30"
max_sdk_version: ""
}
jars {
path: "/apex/com.android.mediaprovider/javalib/framework-pdf.jar"
classpath: BOOTCLASSPATH
min_sdk_version: "30"
max_sdk_version: ""
}
jars {
path: "/apex/com.android.mediaprovider/javalib/framework-pdf-v.jar"
classpath: BOOTCLASSPATH
min_sdk_version: "34"
max_sdk_version: ""
}
// min_sdk_version values were empty previously

Change-Id: Ia547747b16d255c1a093deee96a1abb61fd47dff
2024-06-12 17:12:56 +00:00
Tomasz Wasilczyk
a5db0203c4 Merge "Enable cmake testing" into main am: ff18ea26f8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3123791

Change-Id: Iffdb6bc3bf26d234b331f390a4a8fdccfaa126f8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 15:56:09 +00:00
Tomasz Wasilczyk
ff18ea26f8 Merge "Enable cmake testing" into main 2024-06-12 15:37:06 +00:00
Treehugger Robot
423e5d1c3f Merge "build_flag: when printing all flags, sort them." into main am: 0499f2c687
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3126513

Change-Id: I8da6d562028cd761c3fbb54213dab56cfb45847e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 02:47:28 +00:00
Treehugger Robot
0499f2c687 Merge "build_flag: when printing all flags, sort them." into main 2024-06-12 02:21:23 +00:00
LaMont Jones
6c8ea22a94 Merge changes Ib0f26c98,Ie4e74bce into main am: 0bfb255d26
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3125695

Change-Id: If47c184a80d83e5d84b7f364cd8ffccede059ddb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-12 00:47:35 +00:00
LaMont Jones
0bfb255d26 Merge changes Ib0f26c98,Ie4e74bce into main
* changes:
  build-flag: support `set --redacted=true NAME`
  build-flag: ensure release_config declaration exists
2024-06-12 00:28:15 +00:00
Sam Saccone
695908cf6d Merge "Only generate kythe xrefs on the primary module" into main am: 6ace4cf906
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3126514

Change-Id: Id836a095e7f3c3f22fca1ed470b832da6677fb59
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-11 23:17:50 +00:00
Tomasz Wasilczyk
c3177e0ffc Enable cmake testing
Bug: 302718225
Test: atest binder_sdk_test
Change-Id: Id841d73d11f3b0c75f7bcd523be8ff69300a503e
2024-06-11 13:36:20 -07:00
Sam Saccone
6ace4cf906 Merge "Only generate kythe xrefs on the primary module" into main 2024-06-11 20:23:38 +00:00
mrziwang
8937176646 Use OutputFilesProvider on prebuilt_etc
In the context of incremental soong, the output files
inter-module-communication will be through OutputFilesProvider.
The OutputFileProducer interface will be deprecated.

Test: CI
Bug: 339477385
Change-Id: Ibd64f7e526f39a067ce395b32b87d3fdb117a573
2024-06-11 12:42:24 -07:00
Cole Faust
9decf834ce Only generate kythe xrefs on the primary module
Currently the kythe build is hitting the 6 hour timeout, but we're
generating kythe files for all variants. Generating them only for
the primary variant should drastically cut its runtime.

Bug: 345440993
Test: Presubmits
Change-Id: I3846b25c7f0bc22153e4f0a0cb81c5015854dd70
2024-06-11 11:50:47 -07:00
Zi Wang
05ae2e9d35 [conflict] Merge "PrebuildEtcModule no longer implements OutputFiles method" into main am: 3125b75d5d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3123797

Change-Id: I9acefd1def06cefc153514c766489b341fa86b2e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
Ignore-AOSP-First: to resolve merge conflict
2024-06-11 18:18:14 +00:00
Zi Wang
3125b75d5d Merge "PrebuildEtcModule no longer implements OutputFiles method" into main 2024-06-11 16:55:22 +00:00
LaMont Jones
50cf9be45c build_flag: when printing all flags, sort them.
Bug: None
Test: manual
Change-Id: I1d3d6e9d9e56d2987e43e4a41162df4d3c39ad31
2024-06-11 09:52:05 -07:00
Pirama Arumuga Nainar
b2fa85de8c Merge "Revert^8 "Upgrade to clang-r522817"" into main am: 658bd0540e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3122593

Change-Id: Ib620d6f7dcaf6ceca09d5e554580b64020ba4d03
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-11 16:27:21 +00:00
Pirama Arumuga Nainar
812d8de86c Merge "Revert^2 "rustc-1.78.0 Build 11910258"" into main am: 44755fa745
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3122592

Change-Id: I2e327e174f5265c20217e77cb9a5e9a67e80f71f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-11 16:27:18 +00:00
Tomasz Wasilczyk
273ee50904 Merge "cc_cmake_snapshot: fix cc_test and cc_benchmark" into main am: e07a19bc63
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/3107165

Change-Id: I67ae035ef0f008bd5211f6d53543dfb3ab175b3c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2024-06-11 16:26:59 +00:00
Pirama Arumuga Nainar
658bd0540e Merge "Revert^8 "Upgrade to clang-r522817"" into main 2024-06-11 16:25:58 +00:00
Pirama Arumuga Nainar
44755fa745 Merge "Revert^2 "rustc-1.78.0 Build 11910258"" into main 2024-06-11 16:25:58 +00:00
Tomasz Wasilczyk
e07a19bc63 Merge "cc_cmake_snapshot: fix cc_test and cc_benchmark" into main 2024-06-11 16:04:36 +00:00