Jihoon Kang
c8e1d69687
Add --classes optional flag in list_files
...
The flag enables list_files to output a list of .class files pattern
that will be generated when compiling the java files in the input
directory. The flag can be used to extract the appropriate class files
from stub jar file provided via dep_api_srcs in per api scope
sdk_library generated java_api_library modules.
Test: m --build-from-text-stub in same topic
Bug: 275570206
Change-Id: I134fcd9781024dcb6781297d02645f5fb9befb18
2023-06-27 04:46:50 +00:00
Jooyung Han
2ac1f2fabc
Deprecate flattened apexes
...
Flattened apexes are deprecated. mege_dexopt does not need to care about
flattened apexes.
Bug: 278826656
Test: m otapackage
Change-Id: I527eed64c5f1a7466e2c48d73360f47f6cfa0911
2023-06-27 13:01:56 +09:00
Xin Li
24c928cda8
Merge "Merge Android 13 QPR3"
2023-06-26 22:29:55 +00:00
Treehugger Robot
40fe34bdc6
Merge "aconfig: add dump --format=textproto" am: 571cd07796
am: f29ee8722d
am: 475043109a
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2637956
Change-Id: I66a8c11e0e63dc6e206fa975ef6a2f651735f499
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-26 16:29:21 +00:00
Treehugger Robot
f29ee8722d
Merge "aconfig: add dump --format=textproto" am: 571cd07796
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2637956
Change-Id: Idc6f136fb0b5592ad7662272258ec756fea73dbc
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-26 15:03:19 +00:00
Mårten Kongstad
3228b29cac
aconfig: add dump --format=textproto
...
Teach `aconfig dump` to print its as text protobuf.
Bug: 288713733
Test: atest aconfig.test aconfig.test.java
Change-Id: Id31ce53226162a563fbe2d4841a8f6cf96c22436
2023-06-26 10:17:42 +02:00
Mårten Kongstad
3f0151dcc7
Merge "aconfig: add proto bug
field" am: 37cb74b3e4
am: 4a294a65b4
am: 4c30c59324
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2634549
Change-Id: Icc1379d0e62cd84f835c0088da8b63502cb1aba3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-26 08:09:16 +00:00
Mårten Kongstad
4a294a65b4
Merge "aconfig: add proto bug
field" am: 37cb74b3e4
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2634549
Change-Id: I0c846a9c290ab59f1dc3a46e9d519f9a318c5793
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-26 06:38:33 +00:00
Mårten Kongstad
37cb74b3e4
Merge "aconfig: add proto bug
field"
2023-06-26 06:27:48 +00:00
Joe Onorato
4a80353011
Merge "Rename device_config --> aconfig and definitions --> declarations" am: 9ccb457588
am: 958b906ed8
am: a83f50d161
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2633872
Change-Id: If9360ebd0acebe85f42f89a268c316d51c765708
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-22 15:36:36 +00:00
Mårten Kongstad
1b8636bd7d
aconfig: add proto bug
field
...
Add a `bug` field on the flag_declaration and parsed_flag proto
messages. This field is optional in the sense that it can occur zero or
more times, and aconfig will simply pass any value through.
Bug fields are included in the aconfig dump format, which can be
processed by other tools.
Also unify how protos.rs checks that fields marked 'optional' in the
proto file, but in practice are 'required', are actually set.
Test: atest aconfig.test aconfig.test.java
Bug: 288261336
Change-Id: I93de0005674822c6ff4d699bdc2c6509763a7f7f
2023-06-22 16:50:33 +02:00
Joe Onorato
958b906ed8
Merge "Rename device_config --> aconfig and definitions --> declarations" am: 9ccb457588
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2633872
Change-Id: I0cb0c21ac2df9a34caf4e82346007674f49c97d0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-22 14:10:22 +00:00
Joe Onorato
9ccb457588
Merge "Rename device_config --> aconfig and definitions --> declarations"
2023-06-22 13:30:53 +00:00
Treehugger Robot
767b6bc6e8
Merge "Handle symlinks when extracting zipfiles" am: 0e5e1749bb
am: f6399f8b17
am: 444bb1c08e
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2632808
Change-Id: Iaa75915a875a76df5d654cc60001dce4a52ad6d2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-22 03:59:23 +00:00
Treehugger Robot
f6399f8b17
Merge "Handle symlinks when extracting zipfiles" am: 0e5e1749bb
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2632808
Change-Id: I4316f46baf8d79390a892c1391b89ea50487e4e6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-22 02:29:29 +00:00
Treehugger Robot
0e5e1749bb
Merge "Handle symlinks when extracting zipfiles"
2023-06-22 01:27:35 +00:00
Joe Onorato
6aa48f8c5f
Rename device_config --> aconfig and definitions --> declarations
...
Bug: 285303012
Test: for x in next trunk trunk_food trunk_staging ; do lunch aosp_panther-$x-eng ; m nothing ; done
Change-Id: I174ce3e609fa9077ea6bc61679ddb83e8efe57c8
2023-06-21 15:18:15 -07:00
Kelvin Zhang
e473ce9e80
Handle symlinks when extracting zipfiles
...
python3.11's zipfile implementation does not handle symlinks. This
causes important symlinks in ramdisk to be broken, and later causing a
boo failure.
Test: unzip a target files with symlinks, make sure symlinks are created
Bug: 287896098
Change-Id: Ia7d6ac8ffb03807680a36ff648aa11afafb7f481
2023-06-21 13:31:26 -07:00
Mårten Kongstad
2302e3c4be
Merge "aconfig: make proto fields optional" am: a3b0027fdb
am: 0201a71f0c
am: a34196902b
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2627237
Change-Id: I6c0d6c0195b41a71c5f8cb9701784e55ae2ef9f9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 21:34:06 +00:00
Mårten Kongstad
0201a71f0c
Merge "aconfig: make proto fields optional" am: a3b0027fdb
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2627237
Change-Id: I697af95c091cf919fe0f094c03d83f99834d4ad0
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 20:05:02 +00:00
Zhi Dou
5ace4a9cc3
Merge "aconfig: generate Java flag name constants" am: cff292f8b2
am: 1f7e9252ed
am: 6b29eed1a1
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2611170
Change-Id: I72c9c984f1e5f7380e027c6e6ada23c333a296a8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 18:58:44 +00:00
Mårten Kongstad
a3b0027fdb
Merge "aconfig: make proto fields optional"
2023-06-20 18:47:08 +00:00
Zhi Dou
1f7e9252ed
Merge "aconfig: generate Java flag name constants" am: cff292f8b2
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2611170
Change-Id: I21da79301c4dc8828c6b4b48923720121dc91342
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 17:32:16 +00:00
Treehugger Robot
0531aac817
Merge "aconfig: use proto struct directly" am: 23788f85a4
am: 7639e644a3
am: 6a5ce4a2a9
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628052
Change-Id: I92b8b44af3956702740f508119c491222fff659c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 17:28:39 +00:00
Zhi Dou
cff292f8b2
Merge "aconfig: generate Java flag name constants"
2023-06-20 16:53:53 +00:00
Treehugger Robot
7639e644a3
Merge "aconfig: use proto struct directly" am: 23788f85a4
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628052
Change-Id: Ie7a63ce89d02bc3fc4fcee4e3080cc86779a167f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 16:04:25 +00:00
Treehugger Robot
23788f85a4
Merge "aconfig: use proto struct directly"
2023-06-20 15:28:58 +00:00
Wei Li
83cdd1f97d
Merge "Include static libraries information in Android SBOM." am: c20175155a
am: 7f298d8a1a
am: 98a187fb69
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2609475
Change-Id: I16510d59533dc69cbeeeddaefaba91e691631949
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-20 00:19:01 +00:00
Wei Li
7f298d8a1a
Merge "Include static libraries information in Android SBOM." am: c20175155a
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2609475
Change-Id: I342757931802a04dd09d0f50e3eea2219fdd5948
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 22:51:32 +00:00
Wei Li
c20175155a
Merge "Include static libraries information in Android SBOM."
2023-06-19 22:02:20 +00:00
Treehugger Robot
26fb87e0fd
Merge "Fix usage message." am: fb8c86513e
am: 9d9e540cc5
am: 8b1c423839
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2625356
Change-Id: I807ef4d81821548df70ead6fc3db2bde6ce3d75d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 21:19:17 +00:00
Treehugger Robot
0a12cee3aa
Merge "Fix godoc typos." am: d999938ab0
am: 6df5275646
am: b89f8537cc
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628611
Change-Id: I656792d1b06e40d378b4cbccf39cc1550cf646d5
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 21:19:03 +00:00
Treehugger Robot
9d9e540cc5
Merge "Fix usage message." am: fb8c86513e
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2625356
Change-Id: I7b1b9db8ded7ae73aa94152c66032aebffaa2186
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 19:53:45 +00:00
Treehugger Robot
6df5275646
Merge "Fix godoc typos." am: d999938ab0
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628611
Change-Id: I7a4b16d885e777143143d8beeffea38ddd77b6e3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 19:53:30 +00:00
Treehugger Robot
fb8c86513e
Merge "Fix usage message."
2023-06-19 19:20:15 +00:00
Treehugger Robot
d999938ab0
Merge "Fix godoc typos."
2023-06-19 19:10:47 +00:00
Mårten Kongstad
a2e5ab82c7
aconfig: make proto fields optional
...
Change all required proto fields to optional. While the proto file is
supposed to be a backwards compatible API, and fields are not supposed
to be deprecated, this commit will allow for that option if needed.
Implementation wise this change doesn't matter much: any parsed data
needs additional verification outside what the protobuf crate's parser
provides anyway, so adding checks to verify that all required fields,
even though marked optional in the proto file, were found is a minor
increase in code complexity.
If in the future a proto field should no longer be used:
- keep the field in the proto, still marked optional and clearly
document that it is no longer in use
- change protos.rs from checking struct.has_field() to explicitly
dropping any value via struct.clear_field()
Bug: 286337317
Test: atest aconfig.test
Change-Id: Iad1ccfe50ecac286ff7a796aec909bec70b9520d
2023-06-19 16:53:22 +02:00
Mårten Kongstad
a2e152a139
aconfig: generate Java flag name constants
...
Generate Java constants for use in @FlaggedApi(flag = ...).
Also update the generated Java code to use the constants when reaching
out to DeviceConfig instead of hard-coding (duplicate) strings.
Bug: 285288440
Test: atest aconfig.test aconfig.test.java
Change-Id: I1127cacba650cc7a7896b1533e03631d7f5ec71b
2023-06-19 16:12:01 +02:00
Mårten Kongstad
403658f9cb
aconfig: use proto struct directly
...
Remove the hand-crafted wrappers around the structures auto-generated
from protos/aconfig.proto, and use the auto-generated structs directly
intead. This gets rid of a lot of manual repetition, and its inherent
risk.
Also unify how individual fields read from text proto are verified (e.g.
is the flag.name field a valid identifier).
Also change the intermediate cache format from JSON to binary protobuf.
The concept of a 'cache' as an intermediate internal format to represent
parsed input stays. The command line interface still refers to caches.
At the moment a cache file is identical to a parsed_file protbuf, and
the code exploits this internally.
A couple of points regarding the auto-generated structs:
- Vectors are named in the singular (e.g. parsed_flags.parsed_flag is
a Vec<ProtoParsedFlag>) because this improves ergonomics for all
devs working with aconfig input files
- The auto-generated structs have fields that are of type Option<T>
and convenience methods (named the same as the fields) to access T
Test: atest aconfig.test aconfig.test.java
Bug: 283910447
Change-Id: I512820cc4bc6c543dea9f6a4356f863120a10be3
2023-06-19 16:04:32 +02:00
Treehugger Robot
3a2c089415
Merge changes from topic "aconfig-prepare-for-proto-structs" am: a99ac90eb5
am: 36e4f3fb37
am: 643be21ccb
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628050
Change-Id: I5c5138bdba4275aee2eab015e3246f64c8715acd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 12:51:37 +00:00
Treehugger Robot
36e4f3fb37
Merge changes from topic "aconfig-prepare-for-proto-structs" am: a99ac90eb5
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628050
Change-Id: I11dc893158f85eb104ac8085714079c5ca3ad6ef
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-19 11:28:46 +00:00
Treehugger Robot
a99ac90eb5
Merge changes from topic "aconfig-prepare-for-proto-structs"
...
* changes:
aconfig: fix incorrect source path in test cache
aconfig: reduce number of #[cfg(feature = "cargo")] uses
2023-06-19 10:43:34 +00:00
Treehugger Robot
dab757ddc2
Merge "Handle zip64 extra fields better" am: 57c1aa7b16
am: 5c3a34b358
am: acddbb78de
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628431
Change-Id: I40f8a83bcd76d49a4512f3f26079442696e07fc3
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-18 00:45:05 +00:00
Treehugger Robot
5c3a34b358
Merge "Handle zip64 extra fields better" am: 57c1aa7b16
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2628431
Change-Id: Ieefcc8ee08c2d91f447fc5209967d43db7454c75
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-17 23:04:21 +00:00
Treehugger Robot
57c1aa7b16
Merge "Handle zip64 extra fields better"
2023-06-17 22:12:26 +00:00
Kelvin Zhang
1e774245a4
Handle zip64 extra fields better
...
Test: check_target_files_signatures
Bug: 283033491
Change-Id: I7da89f8389c09cc99201cff342483c158bd7e9c1
2023-06-17 09:21:46 -07:00
Wei Li
d263695cd4
Include static libraries information in Android SBOM.
...
Bug: 280852724
Test: CIs
Test: lunch aosp_cf_x86_64_phone-userdebug && m sbom
Change-Id: Ie2365d79ba24910b7ace132b578589be10a17d78
2023-06-16 23:02:09 -07:00
Treehugger Robot
4b6b6f95d2
Merge "Use patch instead of git apply." am: 0d2d11bc00
am: 251eac36ab
am: c3afc51e86
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2627735
Change-Id: I6db10d07636ab82de5b9366f4687b94713472b4c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-17 04:19:12 +00:00
Treehugger Robot
251eac36ab
Merge "Use patch instead of git apply." am: 0d2d11bc00
...
Original change: https://android-review.googlesource.com/c/platform/build/+/2627735
Change-Id: Ia63a8d9eb8877d763bcfee18beedba41d775c481
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com >
2023-06-17 02:49:12 +00:00
Treehugger Robot
0d2d11bc00
Merge "Use patch instead of git apply."
2023-06-17 01:56:52 +00:00