Commit graph

62644 commits

Author SHA1 Message Date
Elliott Hughes
e4793bc73f Allow SCS for riscv64 too.
Bug: https://github.com/google/android-riscv64/issues/55
Test: treehugger
Change-Id: I319fc662c1dd6083757f78b8d91ec2775ef94a46
2023-02-10 01:53:17 +00:00
Christopher Parsons
a9242e32d5 Merge "Only write soong_injection files if changed" 2023-02-06 22:23:54 +00:00
Chris Wailes
bae5f4c472 Merge "Revert "rustc-1.66.1 Build 9561314"" 2023-02-06 21:09:55 +00:00
Colin Cross
676e15a452 Merge "Use platform libc++ for riscv64 sdk variants" 2023-02-06 20:56:17 +00:00
Chris Wailes
83ed187b2a Revert "rustc-1.66.1 Build 9561314"
Revert submission 2421642-rust-update-prebuilts-1.66.1

Reason for revert: Missing riscv support and out of date base64 crate causing brekages

Reverted changes: /q/submissionid:2421642-rust-update-prebuilts-1.66.1

Change-Id: I6c0d6c3539e766012570e4542f529706fe49928c
2023-02-06 20:36:37 +00:00
Alix Espino
ade518ad6e Merge "refactor android_app bp2build" 2023-02-06 19:13:02 +00:00
Chris Wailes
ee46ca29c4 Merge "rustc-1.66.1 Build 9561314" 2023-02-06 18:16:21 +00:00
Jihoon Kang
800f64078c Merge "Prevent dynamically created java_api_contribution from inheriting parent modules' visibility" 2023-02-06 17:31:10 +00:00
Almaz Mingaleev
e0cab5c47f Merge "Add jdk.internal.util.jar in the allowed package list." 2023-02-06 16:52:43 +00:00
Alix
733110e745 refactor android_app bp2build
Test: bp2build tests and locally built MusicKotlin
Change-Id: Ia5a58b26717a0252e3ae87ea68182e6f2b5c60cf
2023-02-06 15:39:16 +00:00
Jihoon Kang
42b589cd61 Prevent dynamically created java_api_contribution from inheriting
parent modules' visibility

By default, dynamically created module inherits the parent module's
visibility. When the parent module's visibility is set to
"//visibility:private" or has any other specified visibility
restrictions in the module definition,  the created
java_api_contribution module is not visible to java_api_library.
Thus, override any inherited visibility properties and set the visiblity
of the created java_api_contribution module to public.

Test: m
Change-Id: I5db60a5a1800e2ae28c9650eeb9a2f1c3b4f8989
2023-02-04 00:29:33 +00:00
Chris Wailes
b85d7d459b rustc-1.66.1 Build 9561314
Bug: https://issuetracker.google.com/issues/263153841
Test: m rust
Change-Id: If7d96b940269d7be0bafc972ce78b4e14f8be09e
2023-02-03 15:52:51 -08:00
Chris Parsons
3a8d0fbede Only write soong_injection files if changed
This also fixes determinism of these files (by ensuring that bazel
requests and their configurations are sorted, as these are used in the
soong_injection file output)

Bug: 266983462
Test: Manually verified soong_injection files are the same among
multiple runs
Test: Unit test
Test: m nothing

Change-Id: I1568930549cff0bc5676825434cc448d16ebdd4e
2023-02-03 18:29:02 -05:00
Almaz Mingaleev
8b04d82ff1 Add jdk.internal.util.jar in the allowed package list.
This is part of OpenJDK17 update. sun.misc.JarIndex was moved to
jdk.internal.util.jar.

Bug: 260718199
Test: m
Change-Id: I7107f980d6afe500acff88164b1e6cb04cded896
2023-02-03 11:42:46 +00:00
Chris Wailes
28f4af7955 Merge "Turn stable-features error into a warning" 2023-02-03 09:36:02 +00:00
Chris Wailes
0152dd9d69 Turn stable-features error into a warning
This CL turns the stable-features lint into a warning.  This is
necessary to complete toolchain updates until we finish enforcing the
"no unstable features policy".

Test: ./test_compiler --prebuilt-path ../../dist/rust-1.66.1.tar.gz
Bug: 267698452
Bug: 263153841
Change-Id: Ib095dea045111ad3d89327a694aa5fa5b7f3128c
2023-02-02 22:05:19 -08:00
Treehugger Robot
69ef681c13 Merge "bp2build kt for android_binary" 2023-02-02 23:34:59 +00:00
Alix
0856f9e227 bp2build kt for android_binary
Test: bp2build tests and locally built MusicKotlin
   (cannot allowlist yet due to soong/bazel custom_package differences)
Change-Id: I1cbd0fe2af0e6eeed65cf8d57dc85c1f54646c50
2023-02-02 20:26:01 +00:00
Kelvin Zhang
d60722c204 Merge "Revert "Target Java 17"" 2023-02-02 18:51:26 +00:00
Sorin Basca
384250c7c4 Revert "Target Java 17"
This reverts commit d6be9e51ca.

Reason for revert: b/267608166.

Change-Id: Ie07caa5ace3bcb290829e6fa476c5e1d47b975ba
Fixed: 267608166
2023-02-02 17:56:19 +00:00
Dennis Shen
a928c8dae1 Merge "Add soong unit test for trimmed apex build" 2023-02-02 14:39:53 +00:00
Sam Delmerico
1978fdf9b2 Merge "clean up CL for androidmk variables" 2023-02-02 14:11:12 +00:00
Sorin Basca
24bfad66be Merge "Use a stub doclet instead of Doclava" 2023-02-02 11:38:32 +00:00
Sorin Basca
ac9938dddc Merge "Target Java 17" 2023-02-02 11:38:32 +00:00
Yu Liu
249998d290 Merge "Denylist libunwindstack for now until later." 2023-02-02 07:07:40 +00:00
Yu Liu
828c4065e1 Denylist libunwindstack for now until later.
Bug: 266446882
Test: b and m build tzdata and adbd
Change-Id: Idb931c37b082743251aae0e633fd7e51ca651a9b
2023-02-01 20:40:42 +00:00
Dennis Shen
d4f5d932a1 Add soong unit test for trimmed apex build
BUG: b/259381334
TEST: m nothing
Change-Id: I49e5d31a6f5c4f9a72a6a4b3b2ab7114b996adbc
2023-02-01 20:23:46 +00:00
Yabin Cui
43d873625f Update bindgen clang version to r475365b
Bug: 253033919
Test: build
Change-Id: I2fd71206a540da7001956f1f6f5aae5d4f925920
2023-02-01 11:17:09 -08:00
Treehugger Robot
fd659ef7da Merge "Remove R8-specific flags from soong config" 2023-02-01 17:18:42 +00:00
Sam Delmerico
acddda07de Merge "remove errorprone/processor classpath from r8 flags" 2023-02-01 16:01:32 +00:00
Zhi Dou
7fc88d5f49 Merge "Make min_sdk overridable in override_apex" 2023-02-01 13:59:14 +00:00
Treehugger Robot
67a7ab89cf Merge "Stop ignoring the targetSdkVersion when it includes the API fingerprint SHA" 2023-02-01 13:42:07 +00:00
Spandan Das
357ebe5e6d Merge "Doc updates for #apex and #systemapi" 2023-02-01 01:39:53 +00:00
Spandan Das
92b6e8ec72 Merge "Java API export of CorePlatformApi surface" 2023-02-01 01:20:11 +00:00
Paul Duffin
aa2aad6d0f Stop ignoring the targetSdkVersion when it includes the API fingerprint SHA
Change https://r.android.com/1959021 introduced a regression in the
handling of the `targetSdkVersion` when using the API fingerprint.
Prior to that change, when `UseApiFingerprint(ctx)` returned true that
would cause all APKs (apart from `framework-res`) that were built to
use a `targetSdkVersion` that included the API fingerprint SHA. After
that change the `UseApiFingerprint(ctx)` had no effect on the setting
of `targetSdkVersion`.

This change corrects that.

Bug: 266899206
Test: UNBUNDLED_BUILD_SDKS_FROM_SOURCE=true UNBUNDLED_BUILD_TARGET_SDK_WITH_API_FINGERPRINT=true TARGET_BUILD_APPS="NetworkStack" m
      aapt2 dump badging out/target/product/generic/system/priv-app/NetworkStack/NetworkStack.apk
      # Run above before and after this change and see that the targetSdkVersion
      # has changed to `UpsideDownCake.<SHA>`.
Change-Id: Ic6e1da552c565cc4bd75cc734b3acb7faec67981
2023-02-01 00:03:09 +00:00
Spandan Das
24df3c20e7 Doc updates for #apex and #systemapi
These include
- Drop the synonym sentence. With the enforcement introduced in
  aosp/2153678, they can no longer be used interchangeably
- Add information that a single .map.txt file cannot contain both these
  two annotations.
- Link a bug that provides additional context on why this granularity
  is necessary.

Test: N/A
Bug: 266824291
Change-Id: I31b49d492ec56f2f6f0b88de6e608e4ec6fe7011
2023-01-31 22:23:32 +00:00
Sam Delmerico
704d6b9a62 remove errorprone/processor classpath from r8 flags
This classpath includes compile-time-only jars that may conflict with program/library jars referenced by R8 and used by the target.

Test: go test ./java
Test: m && inspect output for r8 warnings
Bug: 242088131
Change-Id: Id4db3c9482e78cdcc0c9d37b9a77eaf94ac95cb3
2023-01-31 21:56:54 +00:00
Treehugger Robot
f987b38cf9 Merge "Remove unused field 'subAndroidMkOnce'." 2023-01-31 21:52:29 +00:00
Christopher Ferris
1f4ccd2ada Merge "HWAsan: Increase the malloc fill size." 2023-01-31 21:45:18 +00:00
Jared Duke
6587cecab3 Remove R8-specific flags from soong config
Instead, move them to R8Wrapper. Having all of these R8-specific flags
in a single location, bundled within the R8 repo, is easier to maintain.
This should be a no-op for generated code.

Test: m + validate identical dex output
Change-Id: Ibdeecef8ca5d311d353dd623c73fab608ccd2681
2023-01-31 12:45:00 -08:00
zhidou
133c55b48a Make min_sdk overridable in override_apex
It makes sense to make min_sdk overridable because the override_apex is
a variant of the original apex, and this variant might be
created/introduced in the newer Android release compared with the base
apex. Despite the fact that the source of the variant apex is the same
as the original one, the variant may not support the older version, like
Go modules, trimmed modules. If we consider the variant as a "new"
module, then it makes sense to have a new min_sdk to make it only
available for the newer Android released version only.

Bug: 266945903
Test: Build locally, and check if the override works
Change-Id: I7f4c7169e15b7e57f44a4abafe012151dbc226a0
2023-01-31 19:34:55 +00:00
Jared Duke
8e0ae8e960 Merge "Enable same-file policy for R8 optimizations" 2023-01-31 16:54:42 +00:00
Spandan Das
da97755329 Java API export of CorePlatformApi surface
API export currently uses a naming convention to determine the api
surface of a droidstubs module. Add platform.api to this naming
convetion for CorePlatformApi surface

Test: N/A
Bug: 262014796
Change-Id: I1255e7e54d4a1dfb9e040184b90d6e8b7146c028
2023-01-30 23:54:11 +00:00
Treehugger Robot
9bedfd0d4b Merge "Rename API surface provided to mainline modules" 2023-01-30 23:06:22 +00:00
Christopher Parsons
94f8a60f5d Merge "Fix nondeterminism in bp2build" 2023-01-30 22:58:17 +00:00
Chris Parsons
7b3289b471 Fix nondeterminism in bp2build
This fixes two main sources of nondeterminism:

1. Fix a bug in the ConfigurationAxis comparator (which caused
   ConfigurationAxis sorting to be nondeterministic)
2. Process C++ dependencies using the sorted ConfigurationAxis order. In
   theory, the order in which dependencies are processed shouldn't
   matter (as they should end up in different select stanzas). However,
   in the case of InApex stubs, this is not the case; we now ensure
   that lists are concatenated in a predictable order.

Added bonus: Some cleanup with SortConfigurationAxes which
makes use of go generics (this made it easier to debug this issue).

Will follow-up with regression tests.

Test: Manually verified that build.ninja checksum and BUILD.bazel checksums do not change after running `m nothing` 6 times in AOSP (with comment-only Android.bp changes in between each run)

Change-Id: I81168e45bdbbcd61ea95ff665cf6c4bc180aa4e0
2023-01-30 21:26:57 +00:00
Usta (Tsering) Shrestha
e136efdcfa Merge "prune out empty bazel depsets" 2023-01-30 21:04:08 +00:00
Usta (Tsering) Shrestha
28b5ac6db5 Merge "soong_build cmline args validation" 2023-01-30 20:50:44 +00:00
Cole Faust
56080ddc08 Merge "Precompile python sources" 2023-01-30 20:02:27 +00:00
Treehugger Robot
f21f25f172 Merge "Delete apexBundle#prebuiltFileToDelete." 2023-01-30 18:30:57 +00:00