Commit Graph

5559 Commits

Author SHA1 Message Date
Keun-young Park
131f70c34b Merge "Make car apex's library optional in PRODUCT_APEX_SYSTEM_SERVER_JARS" 2021-10-19 13:52:19 +00:00
Keun young Park
6e3ba9ac3b Make car apex's library optional in PRODUCT_APEX_SYSTEM_SERVER_JARS
- car-frameworks-service-module is added from com.android.car.framework
  apex which only exisits in car products.

Bug: 203233647
Bug: 203201931
Test: build, bootup
Change-Id: I5f13b0505c1ac4fd2fd7b6559e080c8a6fb526e0
2021-10-19 00:47:47 +00:00
Colin Cross
45c494ce73 Merge changes Ifa4594ea,Ia756f309 am: d26943459d am: 9fe62908b3 am: 710f9ae1b6 am: 232c3fdbc9 am: 0af4f628f5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1861274

Change-Id: I6180d5c3477c2d209c6f3816e6a0f9662b4a5f6e
2021-10-18 23:27:10 +00:00
Colin Cross
d26943459d Merge changes Ifa4594ea,Ia756f309
* changes:
  Reduce commands per shard for java protos
  Up per-product memory usage to 30 GB
2021-10-18 22:03:43 +00:00
Colin Cross
93fa5ef99d Reduce commands per shard for java protos
`m platformprotos` with a long OUT_DIR can trigger E2BIG errors in
posixspawn, reduce the commands per shard.

Test: OUT_DIR=$PWD/really-long-out-directory m platformprotos
Change-Id: Ifa4594eac7ba0e1091df0ef75e4dfc3ff366939b
2021-10-18 10:19:03 -07:00
Jiakai Zhang
182527ce57 Merge "Extract the logic of setting Uncompress_dex to a common place." am: ae9ba1c93a am: c5e71ecc55 am: 3853562adb am: fb62fad630 am: 0a97d7bae8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1853133

Change-Id: Ie7af841b4828ecef2ba1380e2b7412f2f084d264
2021-10-15 04:41:00 +00:00
Treehugger Robot
0821b3bff7 Merge "Add android_sdk_repo_host to build platform-tools&build-tools" am: adf2b3e68f am: e89cd9f2b5 am: 57fbf57305 am: 4dc404e3bc am: de46f5cc11
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1828170

Change-Id: I36da12f89cd704d3f3174490ee7f74da2c6fd959
2021-10-15 03:39:17 +00:00
Jiakai Zhang
ae9ba1c93a Merge "Extract the logic of setting Uncompress_dex to a common place." 2021-10-15 03:30:47 +00:00
Dan Willemsen
9fe1410213 Add android_sdk_repo_host to build platform-tools&build-tools
The Android SDK has been built with Make up until now, monolithically,
then split up into several sdk-repo zip files for different purposes.
The Mac and Windows SDKs really only need to contain the platform-tools
and build-tools pieces, but due to this monolithic sdk zip, we had to
build the whole SDK first.

This adds an `android_sdk_repo_host` module that can build these
platform-tools and build-tools zips.

Bug: 187222815
Change-Id: I55809e1d7447dd65e22461f921b2b8abb6d5f822
2021-10-13 01:25:02 -07:00
Steven Moreland
ba2027d6dd Merge "Allow defaults in java_genrule modules" am: 371dc53d18 am: f11c08ab55 am: 5652357cbc am: 29481a8e42 am: c2dee33c8e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1850961

Change-Id: I3d3dd2eb4bf14b86c190c211779aef8ad6e1c874
2021-10-11 19:19:25 +00:00
Steven Moreland
371dc53d18 Merge "Allow defaults in java_genrule modules" 2021-10-11 17:47:22 +00:00
Anton Hansson
bd3b0d8a6d Merge "Update reference to merged services txt" am: 6fcddda43c am: 776a2bcb7e am: 3461a8a266 am: 1e27eb95d0 am: 46296bc360
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1850001

Change-Id: Ic43ff501a1c985926e7604750c1a79dd10aa9527
2021-10-11 17:03:50 +00:00
Anton Hansson
6fcddda43c Merge "Update reference to merged services txt" 2021-10-11 15:57:02 +00:00
Jiakai Zhang
22450f25da Extract the logic of setting Uncompress_dex to a common place.
Bug: 194150908
Test: m nothing
Change-Id: Ia33965067586cfd48183e6d17f5d17626eef3c5a
2021-10-11 03:05:20 +00:00
Colin Cross
99c3ed94b8 Allow defaults in java_genrule modules
Call InitDefaultableModule in java_genrule factories to allow
the defaults property to be used.

Bug: 202547639
Test: m checkbuild
Change-Id: I3a5960304af3e9babb30d036d63016087000d773
2021-10-08 17:52:32 -07:00
Anton Hansson
f2dffd9c04 Update reference to merged services txt
The module is changing name. Update the reference.

Bug: 169103987
Test: m
Change-Id: I1e3f05b6d9c0262adcde6881ea79df9338bb363a
2021-10-08 16:15:10 +01:00
Xin Li
800112b97f Merge "Merge Android 12" 2021-10-07 23:50:21 +00:00
Pedro Loureiro
d28e4b7077 Merge "Add module-lib to droidstubs' supported sdk types" am: 2937eb5bb4 am: bba5a387d6 am: ae4d32592a am: 0ac605d99b am: 3257af3c2f
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844312

Change-Id: Ie7462e94b02ff8d15905ae2d624f7c0388cb29bb
2021-10-07 11:23:13 +00:00
Pedro Loureiro
bba5a387d6 Merge "Add module-lib to droidstubs' supported sdk types" am: 2937eb5bb4
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844312

Change-Id: I3a23a868ff9b476bc3c60f01ad756d897829ff3b
2021-10-07 10:29:31 +00:00
Pedro Loureiro
2937eb5bb4 Merge "Add module-lib to droidstubs' supported sdk types" 2021-10-07 10:17:03 +00:00
Paul Duffin
ea14d9c0db Merge "Allow implementation details to be excluded from signature patterns file" am: 6546573ec9 am: dc3951c407 am: ea16a1f94f am: 9083f4ebfa am: 1d5030cc56
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1788094

Change-Id: I412c3ae32e96a3b400bb886b56f5804c8731c2fe
2021-10-06 13:37:38 +00:00
Paul Duffin
dc3951c407 Merge "Allow implementation details to be excluded from signature patterns file" am: 6546573ec9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1788094

Change-Id: I28f0ddcfe3746a8bf37471f9f1c9b9771fab690a
2021-10-06 12:35:12 +00:00
Paul Duffin
fca846b4eb Retry: Separate hidden API flags needed in sdk snapshots for S and T am: 191be3a186 am: bf027e4e58 am: 1f45d4a4d9 am: 16a312a1e6 am: 812583f057
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844294

Change-Id: I02a215a9702e4c4b2eae3084c0e5e751dfa76f9a
2021-10-05 19:00:18 +00:00
Paul Duffin
bf027e4e58 Retry: Separate hidden API flags needed in sdk snapshots for S and T am: 191be3a186
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844294

Change-Id: Id8977b8160f175b736214428cae94ea27f95675b
2021-10-05 18:04:10 +00:00
Pedro Loureiro
cc203505b9 Add module-lib to droidstubs' supported sdk types
If the android.jar is not found in the module-lib folder, it falls back
to searching it in the system folder and then falls back on the public
folder.

This only brings the functionality, we are not yet using it.

Test: m nothing
Bug: 202023154
Change-Id: I99c9004740c8e51faf53ebc3ba2444e8164215f3
2021-10-05 15:40:46 +00:00
Paul Duffin
1e18e98b14 Allow implementation details to be excluded from signature patterns file
Previously, the signature-patterns.csv file (which was output in an sdk
snapshot) included implementation details, e.g. the names of classes
that are not part of any API, including the hidden API. This change
allows a bootclasspath_fragment module owner to customize the generated
signature patterns file to remove as many implementation details as
possible from the sdk snapshot. That means that implementation only
changes would not require that sdk snapshots be updated in sync with
the corresponding APEX.

Module owners can remove implementation in the following ways:
1) Limit the number of packages that are treated as split packages by
   explicitly specifying the split packages in the split_packages
   property. A split package is one whose classes are provided by
   separate bootclasspath_fragment modules and so the signature
   patterns has to include every class in that package provided by a
   specific bootclasspath_fragment module, including implementation
   classes, instead of just listing the package.

   The default is to treat all packages as being split, so if no
   split_packages is specified then it defaults to ["*"] which matches
   all packages. Assuming that no package was split unless specifically
   stated would require that all the modules that had split packages
   explicitly list them before this change could be submitted as
   without them this change would break the build.

   Once all existing modules with split packages have been updated to
   include them then the default may be changed.

2) Adding package prefixes for any hierarchy of packages that are
   owned solely by that bootclasspath_fragment. This removes the need
   to list the packages in that hierarchy, including implementation
   specific packages.

Bug: 194063708
Test: atest --host verify_overlaps_test signature_patterns_test
      m out/soong/hiddenapi/hiddenapi-flags.csv
      - manually change files to cause difference in flags to check
        that it detects the differences.
Change-Id: If2f90cfc41b6fff9fa4ac8b9d4973110938b9392
2021-10-05 15:47:05 +01:00
Paul Duffin
191be3a186 Retry: Separate hidden API flags needed in sdk snapshots for S and T
Previous change that was reverted: https://r.android.com/1835222
An additional test was added that revealed a bug in the previous change
which has been fixed here.

Previously, the behavior of the stub_flags and all_flags properties
was different between S and T. In S they contained paths for the
complete set of stub flags and all the encoded flags. However, in T
they contained filtered sets of flags which if used in S would prevent
build checks from detecting possible inconsistencies. Also, a new
signature_patterns property was added in T that is not supported in S.

This change creates separate properties/files for T and reverts the
behavior of the properties/files that were added in S back to how they
behaved in S. The new properties are called filtered_stub_flags and
filtered_flags.

The S and T properties are tagged with the appropriate
supported_build_releases tag to ensure that they are only output when
specifically targeted.

Bug: 197842263
Test: m nothing
Change-Id: I1ce0a3d6623dabf73e32af1a7457b9b444fc3b7c
2021-10-05 15:27:42 +01:00
Pedro Loureiro
d9ab7aadf7 Merge "Perform validation of shared library attributes" 2021-10-05 10:15:50 +00:00
Treehugger Robot
28f9c8d9d9 Merge "Bp2Build common properties auto-handling" am: d905146590 am: 3e745e63f3 am: 98f0fd07ca am: 6aaaea1740 am: 37ba2d3f8d
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1815376

Change-Id: I110e0ec8b35ab3f86164e7cbd4db47aa01b65601
2021-10-04 20:15:38 +00:00
Treehugger Robot
3e745e63f3 Merge "Bp2Build common properties auto-handling" am: d905146590
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1815376

Change-Id: I38f1063302ea90583a51e625076e6232b4364ab7
2021-10-04 19:20:28 +00:00
Treehugger Robot
d905146590 Merge "Bp2Build common properties auto-handling" 2021-10-04 19:02:07 +00:00
Ulya Trafimovich
366f689ab7 Update variable name in error messages. am: e5b2b49a73 am: ef92591c59 am: 1fae1299cd am: 79d4a86c7e am: efc3d6caec
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844308

Change-Id: I078fd16c294446f6a6999c452b9cbdad75b8d060
2021-10-04 17:21:30 +00:00
Ulya Trafimovich
ef92591c59 Update variable name in error messages. am: e5b2b49a73
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844308

Change-Id: Icb57f58d9efdf8793162254eefe8e3150d6d9cf5
2021-10-04 16:18:58 +00:00
Ulya Trafimovich
e5b2b49a73 Update variable name in error messages.
Variable PRODUCT_UPDATABLE_SYSTEM_SERVER_JARS was renamed to
PRODUCT_APEX_SYSTEM_SERVER_JARS in https://r.android.com/1779472.

Bug: 191127295
Test: m nothing
Change-Id: I0c8ae839cab443c824760b40d30b4374982010f9
2021-10-04 15:43:39 +01:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
447f6c99c9 Bp2Build common properties auto-handling
Introduce `commonAttributes` & `fillCommonBp2BuildModuleAttrs used in
CreateBazelTargetModule

Adapt `bp2BuildInfo` to use `commonAttrs` instead of `Name`.
And thus also all downstream users of `CreateBazelTargetModule`.

As initial user, the Soong `required` property will be
translated to Bazel's `data`.

Bug: 198146582, 196091467
Test: build_converstion_test.go:TestCommonBp2BuildModuleAttrs
Test: go test
Test: mixed_{libc,droid}.sh
Change-Id: Ib500e40f7e2cb48c459f1ebe3188962fc41ec124
2021-10-04 14:43:04 +00:00
Pedro Loureiro
f9e584dd20 Perform validation of shared library attributes
Perform consistency checks as per http://go/updatable-shared-libraries

These include:
  * no attribute can specified can be less than T
  * max-device-sdk can't be less than min-device-sdk
  * min and max-device-sdk need to be at least the module's
  min_sdk_version
  * using on-bootclasspath-before implies that the module's
  min_sdk_version is at least T or the library has min-device-sdk of at
  least T

Test: m nothing

Bug: 191978330

Change-Id: Iaca5cf23fb0bc7e65effb3529c8e829560894c2e
2021-10-04 14:42:34 +00:00
Paul Duffin
a7c8db44ee Remove unnecessary additionalCheckedModules field am: 0b58fdb058 am: 6c68db45d3 am: 4af54d88fa am: cd7b02f817 am: e838281188
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842815

Change-Id: I13ddf43a823f3255a9b4ee4bbf8d22157302e28c
2021-10-04 12:00:26 +00:00
Paul Duffin
6c68db45d3 Remove unnecessary additionalCheckedModules field am: 0b58fdb058
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842815

Change-Id: Ic6e55395138cfed7257529b2c5165bb4907460e1
2021-10-04 11:11:47 +00:00
Salmax Chang
b8d1ce3c2c Merge changes from topic "bb_201948713" am: 8bb9c6a1d9 am: 12d6b80da2 am: 9386534350 am: 711b068703 am: c06e66c21a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844137

Change-Id: I3a1554618c93276abf6ce3882b87dc1479154d98
2021-10-04 10:09:59 +00:00
Paul Duffin
0b58fdb058 Remove unnecessary additionalCheckedModules field
This change removes the field and the code that uses it which is
effectively dead code as it only does something when the list is not
empty and a previous change removed the only code that added a Path to
this list.

Bug: 201753898
Test: m nothing
Change-Id: I67c74ad2a3b115fd3b20b3b416f45b92c749749c
2021-10-04 10:42:56 +01:00
Salmax Chang
12d6b80da2 Merge changes from topic "bb_201948713" am: 8bb9c6a1d9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1844137

Change-Id: Ia042b5b24141be4ebfa17ab15adf34c3af632635
2021-10-04 08:13:19 +00:00
Salmax Chang
8bb9c6a1d9 Merge changes from topic "bb_201948713"
* changes:
  Revert "Support generating sdk snapshot for specific build release"
  Revert "Separate hidden API flags needed in sdk snapshots for S and T"
2021-10-04 07:53:19 +00:00
Salmax Chang
8194d61ae0 Revert "Separate hidden API flags needed in sdk snapshots for S and T"
This reverts commit ba68c93630.

Reason for revert: suspect to cause build break in b/201948713

Change-Id: Ide3693ac1f8e24bd2f7c12857361885cb6b787ef
2021-10-04 05:28:58 +00:00
Paul Duffin
af2e1b86bd Merge "Separate hidden API flags needed in sdk snapshots for S and T" am: 6b383e9ef2 am: afe55d6598 am: 0385ea00cb am: fe419115a9 am: 0c6ebc66d6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1835222

Change-Id: Id56e96265cf03777bfda6d56c4f3c6ed5e99e20a
2021-10-02 12:30:25 +00:00
Paul Duffin
cbd23f6df5 Merge "Always perform permitted package check when building a library" am: f7db6ebaa1 am: 7f04fb7dbc am: 0c89f5fb04 am: d04cbf5fbb am: 7a228a3e01
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842459

Change-Id: I047ee7a5153a76133000ee3f4ce96a942bacb9cf
2021-10-02 12:29:45 +00:00
Paul Duffin
afe55d6598 Merge "Separate hidden API flags needed in sdk snapshots for S and T" am: 6b383e9ef2
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1835222

Change-Id: I092500dc977cc482a6c662ae9fcd4e71fea32810
2021-10-02 11:34:00 +00:00
Paul Duffin
7f04fb7dbc Merge "Always perform permitted package check when building a library" am: f7db6ebaa1
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1842459

Change-Id: I8be5f7deb33b67b5307cb3a4551f659414a3aee9
2021-10-02 11:33:32 +00:00
Paul Duffin
6b383e9ef2 Merge "Separate hidden API flags needed in sdk snapshots for S and T" 2021-10-02 11:27:45 +00:00
Paul Duffin
f7db6ebaa1 Merge "Always perform permitted package check when building a library" 2021-10-02 11:18:48 +00:00
Treehugger Robot
d7c0c8c4c0 Merge "Preopt APEX system server jars for java_import." am: 6f0c1a1e0c am: 3b54c2b055 am: 3c4cfc88ad am: 63dbb530cf am: 65655e49a2
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1840056

Change-Id: Ic1058266ae3784b33d05865513909de3e08f36f4
2021-10-02 04:50:13 +00:00