Commit Graph

90603 Commits

Author SHA1 Message Date
Kelvin Zhang
d7924a5311 Add missing AB partitions to img.zip
Add all AB partitions to img.zip, so that we can verify integrity of a
build by running avbtool on img.zip .

Bug: 274923679
Test: img_from_target_files on a pixel build. Unzip the generated img
zip, run avbtool verify_image --follow_chain_partitions --image
vbmeta.img, make sure result is successful.

Change-Id: I7d586a6f2ad87d8ebf87b788947055339b1121a2
2023-10-12 10:31:44 -07:00
Kelvin Zhang
ad3c30528d Skip stripping 16K GKI kernel modules
GKI kernel modules are required to be signed, but curretnly we strip all
16K kernel modules. Use SYSTEM_DLKM_MODULE_PATTERNS to determine which
modules are GKI, and skip stripping for these kernel modules.

Test: boot using 16K boot image
Bug: 303725887

Change-Id: I4cd71b39ceb75650d03744220ec4ddf4aeeda871
2023-10-12 10:31:44 -07:00
Cole Faust
392731880a Merge "Add a check that the staging directories don't..." into main am: fe455d1c0c
Original change: https://android-review.googlesource.com/c/platform/build/+/2773149

Change-Id: I1954e5a1901d08965ec2fba3a3d2f50bbd94caa3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-12 16:57:20 +00:00
Elliott Hughes
5fe88a90af Merge "Microoptimize package name extraction." into main am: cf5b792e92
Original change: https://android-review.googlesource.com/c/platform/build/+/2784389

Change-Id: If2c7e371ca4d642467041d5202001b101cdc7429
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-12 16:56:49 +00:00
Cole Faust
fe455d1c0c Merge "Add a check that the staging directories don't..." into main 2023-10-12 16:33:12 +00:00
Elliott Hughes
cf5b792e92 Merge "Microoptimize package name extraction." into main 2023-10-12 16:20:27 +00:00
Treehugger Robot
bf444590bd Merge "APEX extraction rule mentions APEXes" into main am: 6db65332e1 am: fbbd42f172
Original change: https://android-review.googlesource.com/c/platform/build/+/2784034

Change-Id: I6ce0172f5c10992b5d9ee78f33a72c0a7564145d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-12 14:10:28 +00:00
Treehugger Robot
fbbd42f172 Merge "APEX extraction rule mentions APEXes" into main am: 6db65332e1
Original change: https://android-review.googlesource.com/c/platform/build/+/2784034

Change-Id: I00de4b3f0c9e9e91c7a7c6951b74122f8c9b0d2c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-12 13:38:15 +00:00
Treehugger Robot
6db65332e1 Merge "APEX extraction rule mentions APEXes" into main 2023-10-12 12:58:45 +00:00
Jooyung Han
737f6e5c18 APEX extraction rule mentions APEXes
so that it's triggered even when APEX list shrinks.
(-d explain will print "command line changed for ...")

To repro:
- Pick one VAPEX with vintf fragment.
- Copy the fragment to /vendor/etc/vintf/manifest (DEVICE_MANIFEST_FILE)
- `m check-vintf-all` should fail
- Remove the APEX from PRODUCT_PACKAGES
- `m check-vintf-all` should pass

Bug: 304769672
Test: m check-vintf-all
   (see above)
Change-Id: Iae9da91105faebfb8a5127fbb02a414b9ffdca10
2023-10-12 10:39:58 +09:00
Cole Faust
80fad16d14 Add a check that the staging directories don't...
...contain extra files after an installclean.

Bug: 205632228
Test: m installclean && m
Change-Id: Ib021465d1089a21bc4f43306b1441348baf71f9c
2023-10-11 17:42:34 -07:00
Elliott Hughes
707142007b Microoptimize package name extraction.
Since there's only one, and it appears early, we can stop when we find
it rather than trawl through megabytes of localized strings we don't
need to see.

Bug: https://github.com/onetrueawk/awk/issues/199#issuecomment-1756885708
Test: treehugger
Change-Id: If4d7c63da7df76c23fca417a4b727189f79e3ce6
2023-10-11 22:56:22 +00:00
Cole Faust
865d19e214 Enable genrule sandboxing by default
Now that all the failing genrules have been denylisted.

Also add BUILD_BROKEN_GENRULE_SANDBOXING to disable this behavior.

Bug: 290816499
Test: Presubmits
Change-Id: Id7612065ddc976a088ea1ac4c2d959dadf2b845c
2023-10-11 15:24:31 -07:00
Alex Buynytskyy
8b856c1a40 Merge "Fix sepolicy finalization build error" into main am: 9ef1caabed am: c2ddd0e944
Original change: https://android-review.googlesource.com/c/platform/build/+/2784031

Change-Id: Ibd0c2ca5397214e575b800b9ee34030c74e563c2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 16:23:46 +00:00
Alex Buynytskyy
c2ddd0e944 Merge "Fix sepolicy finalization build error" into main am: 9ef1caabed
Original change: https://android-review.googlesource.com/c/platform/build/+/2784031

Change-Id: I3636465be49ee3b5b643af6e967d39b918cc82b8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 15:52:08 +00:00
Alex Buynytskyy
9ef1caabed Merge "Fix sepolicy finalization build error" into main 2023-10-11 15:31:43 +00:00
Vinh Tran
72b7fab580 Add afdo profiles in AOSP to AfdoProfiles product var
Test: m libbinder and inspects build command
Change-Id: Ia72bb7e1baa5790c73cb0213217258517b09c5e9
2023-10-11 11:25:39 -04:00
Dennis Shen
d3faf89bba Merge "aconfig: add missing string header to template" into main am: 268e445503 am: e857396ef5
Original change: https://android-review.googlesource.com/c/platform/build/+/2783599

Change-Id: I6a57b40c00f596857dc095b15247873f5632c985
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 14:30:11 +00:00
Treehugger Robot
79d173edc9 Merge "printflags: improve protobuf decode error message" into main am: dcbe60977c am: 6df36db6b6
Original change: https://android-review.googlesource.com/c/platform/build/+/2779288

Change-Id: I2a2405640a2c512e8f919f9af99b110a06e941e0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 14:30:01 +00:00
Dennis Shen
e857396ef5 Merge "aconfig: add missing string header to template" into main am: 268e445503
Original change: https://android-review.googlesource.com/c/platform/build/+/2783599

Change-Id: Ic55ee442ac9ddc47c0978356de03132ecf5bb1ab
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 14:14:59 +00:00
Dennis Shen
268e445503 Merge "aconfig: add missing string header to template" into main 2023-10-11 14:01:46 +00:00
Dennis Shen
da07fea741 aconfig: add missing string header to template
Bug: 304338314
Test: atest aconfig.test
Change-Id: I97e62ebd9df18d260fd272a8f63a004ba627de9b
2023-10-11 14:00:48 +00:00
Treehugger Robot
6df36db6b6 Merge "printflags: improve protobuf decode error message" into main am: dcbe60977c
Original change: https://android-review.googlesource.com/c/platform/build/+/2779288

Change-Id: I54f8e61be8e9cbc89587c1175db1697acd119dc0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 13:59:03 +00:00
Inseob Kim
4b11cd1a1c Fix sepolicy finalization build error
Bug: 304532197
Test: manually run finalization script
Change-Id: I29f62d7c703081302f1133e881e33fa2ff7d16bf
2023-10-11 22:57:58 +09:00
Treehugger Robot
dcbe60977c Merge "printflags: improve protobuf decode error message" into main 2023-10-11 13:05:02 +00:00
Zhi Dou
13fe9bfa57 Merge "aconfig: add @UnsupportedAppUsage to methods in generated flags" into main am: 057a3dd429 am: 59f91d6e7c
Original change: https://android-review.googlesource.com/c/platform/build/+/2777061

Change-Id: Ib61b9c85410093887e009954d65c3f643aa7347e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-11 00:37:16 +00:00
Zhi Dou
59f91d6e7c Merge "aconfig: add @UnsupportedAppUsage to methods in generated flags" into main am: 057a3dd429
Original change: https://android-review.googlesource.com/c/platform/build/+/2777061

Change-Id: I92c7d78242b6e68bfa1cc70ed44885ad567071b1
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-10 23:30:34 +00:00
Zhi Dou
057a3dd429 Merge "aconfig: add @UnsupportedAppUsage to methods in generated flags" into main 2023-10-10 22:53:54 +00:00
Zhi Dou
22a90f4f10 aconfig: add @UnsupportedAppUsage to methods in generated flags
The java generated flags are marked as @hide which breaks CTS. To
unblock CTS test add @UnsupportedAppUsage to expose the methods.

Test: atest aconfig.test.flags
Bug: 301272559
(cherry picked from https://googleplex-android-review.googlesource.com/q/commit:64ad75f50ae96f9a8b57a9e8f88ae9a53d3c1044)
Merged-In: I897573c054e70fc6e093869ba6d416c38f81e28f
Change-Id: I897573c054e70fc6e093869ba6d416c38f81e28f
2023-10-10 13:55:06 +00:00
Mårten Kongstad
6e61f84fd6 printflags: improve protobuf decode error message
Include the file path and first bytes of file in the error message in
case aconfig fails to parse one of the protobuf files.

Example output:

  $ adb shell printflags
  Error: failed to parse /vendor/etc/aconfig_flags.pb ([0a], 1 byte(s))

  Caused by:
      Unexpected EOF

Bug: 304278614
Test: atest printflags.test
Change-Id: I18ff88bd25d72dd477c4b11a32505e75884906ee
2023-10-10 10:12:29 +02:00
Kelvin Zhang
63192c2ef8 Merge "Run validation on user specified vabc_compression_param" into main am: e52ce13e82 am: a17daca2d4
Original change: https://android-review.googlesource.com/c/platform/build/+/2779731

Change-Id: Id5fd064ea8300e491c561c57d93809a8b4be6b40
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-10 01:22:58 +00:00
Kelvin Zhang
a17daca2d4 Merge "Run validation on user specified vabc_compression_param" into main am: e52ce13e82
Original change: https://android-review.googlesource.com/c/platform/build/+/2779731

Change-Id: I7880ef365a51bb4744a205d442dc81d9f51718a4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-10 00:32:21 +00:00
Anton Hansson
44011c169a Merge changes I66b09cd4,I1847ab2b into main am: a43c06e5d6 am: dd11d060d7
Original change: https://android-review.googlesource.com/c/platform/build/+/2778930

Change-Id: I59f8bbce30f350ae0a558373b91d093dd77a2052
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-10 00:17:34 +00:00
Kelvin Zhang
e52ce13e82 Merge "Run validation on user specified vabc_compression_param" into main 2023-10-09 23:47:37 +00:00
Kelvin Zhang
7d1b29bd5d Run validation on user specified vabc_compression_param
During OTA generation, we check the vabc compression param specified by
target files, and override compression param to gz if the specified
compression method is unsupported. Run the same validation on
compression param passed by --vabc_compression_param as well.

Test: th
Change-Id: If855a2ee8c3c280c74efd5a67df229ab6c5709c5
2023-10-09 16:47:19 -07:00
Anton Hansson
dd11d060d7 Merge changes I66b09cd4,I1847ab2b into main am: a43c06e5d6
Original change: https://android-review.googlesource.com/c/platform/build/+/2778930

Change-Id: I514b0f8324ee03f118aa414e4bbe229917a38c02
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-09 23:40:39 +00:00
Anton Hansson
a43c06e5d6 Merge changes I66b09cd4,I1847ab2b into main
* changes:
  Configure bootclasspath for sdk product
  Remove sdk_<arch> products
2023-10-09 23:10:01 +00:00
Treehugger Robot
7b6c7471fa Merge "Filter REL out of preview codenames." into main am: 6a6e7731be am: bc07c0136e
Original change: https://android-review.googlesource.com/c/platform/build/+/2775701

Change-Id: I741ce9131374a1b18144882c38ababd3902b938e
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-09 21:50:34 +00:00
Treehugger Robot
bc07c0136e Merge "Filter REL out of preview codenames." into main am: 6a6e7731be
Original change: https://android-review.googlesource.com/c/platform/build/+/2775701

Change-Id: I9dc3d74d55866255a2afca94b5e87c8f6cd64460
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-09 21:10:06 +00:00
Treehugger Robot
6a6e7731be Merge "Filter REL out of preview codenames." into main 2023-10-09 20:34:07 +00:00
Elliott Hughes
ba84ad5c90 Merge "Have the sanitizers trap rather than abort." into main am: 14e0d156fb am: 18b102d5c0
Original change: https://android-review.googlesource.com/c/platform/build/+/2777875

Change-Id: Ic9addf8e73f8dceb64eebbe2991e5e5efa7fc17d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-09 18:23:40 +00:00
Elliott Hughes
18b102d5c0 Merge "Have the sanitizers trap rather than abort." into main am: 14e0d156fb
Original change: https://android-review.googlesource.com/c/platform/build/+/2777875

Change-Id: If9cb7b5aeddf5f2cf5e30798f9365e67897c5394
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-09 16:44:10 +00:00
Elliott Hughes
14e0d156fb Merge "Have the sanitizers trap rather than abort." into main 2023-10-09 16:08:06 +00:00
Anton Hansson
dde748a831 Configure bootclasspath for sdk product
The SDK product is currently used to build the SDK sources, which
are the full sources of the bootclasspath. For this to work, the
bootclasspath needs to be configured correctly, so inherit that config.

In the future, it would probably make sense for the sources to be built
together with a device -- the emulator, at which point this config can
be removed.

Bug: 151360309
Test: lunch sdk; m sdk sdk_repo dist
Change-Id: I66b09cd42249c4d5b76f06478781a90108e006e4
2023-10-09 14:41:45 +00:00
Anton Hansson
228de7b72c Remove sdk_<arch> products
The SDK is arch-agnostic, so does not need per-arch products.

Bug: 205008975
Test: presubmit
Change-Id: I1847ab2bae0d07793bdd043430f0e79b36edb384
2023-10-09 14:41:30 +00:00
Treehugger Robot
9ea4ee44b7 Merge "makefile:strip generic ramdisk kernel modules in android build system." into main am: 02eadb873f am: 47744f6c99
Original change: https://android-review.googlesource.com/c/platform/build/+/2775567

Change-Id: I08e4c3e792f555fee709d4850ee2630c56add791
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-07 04:14:13 +00:00
Treehugger Robot
47744f6c99 Merge "makefile:strip generic ramdisk kernel modules in android build system." into main am: 02eadb873f
Original change: https://android-review.googlesource.com/c/platform/build/+/2775567

Change-Id: Ie6a276775c28c787705cb23417bf3536d5a63da4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-07 03:41:22 +00:00
Treehugger Robot
02eadb873f Merge "makefile:strip generic ramdisk kernel modules in android build system." into main 2023-10-07 03:17:16 +00:00
Elliott Hughes
40f0c5cad3 Have the sanitizers trap rather than abort.
abort() seems friendlier, but in practice it puts a couple of irrelevant
libc.so frames on the top of the stack trace and clobbers all the
registers that might have helped remotely debug a sanitizer failure.
Let's switch to trapping directly in the sanitized code instead.

Bug: http://b/298741930
Test: treehugger
Change-Id: I4fca63cb42bfba16a934c1fa88b08697faf3be41
2023-10-06 22:34:36 +00:00
Alyssa Ketpreechasawat
fb0e5d5a90 Merge "Revert "Revert "Add RELEASE_DEFAULT_MODULE_BUILD_FROM_SOURCE in config.""" into main am: 8028a4c59f am: 8404655faf
Original change: https://android-review.googlesource.com/c/platform/build/+/2777427

Change-Id: I69e407d089c97925dfc326c3668ba3e56c72601b
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2023-10-06 19:30:42 +00:00