Commit graph

45470 commits

Author SHA1 Message Date
Colin Cross
11a32a918b Merge "Add phony name for robolectric tests" am: ffe2c918e9
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1831866

Change-Id: I94f283455b3ddecad3d932d7bdbdab902ff211ee
2021-09-24 20:08:33 +00:00
Christopher Parsons
0bb4ac55d6 Merge "Add stl property support for bp2build" 2021-09-24 20:01:12 +00:00
Colin Cross
ffe2c918e9 Merge "Add phony name for robolectric tests" 2021-09-24 19:51:41 +00:00
Christopher Ferris
dea6617bc5 Add two new variables to Malloc_not_svelte.
Add the srcs and header_libs for the system/core/debuggerd
change to support removing scudo code on svelte configs.

Bug: 201007100

Test: Builds.
Change-Id: Iec083dc5cbfbc63334a72e2e77a53067786a85ca
2021-09-24 11:55:51 -07:00
Ivan Lozano
4ac514ff6e Merge "rust: Add require_root and vendor install base" am: eabde18653
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1832614

Change-Id: Iaac35523cc871995c525f066f4601ee3b7e2cd0f
2021-09-24 18:54:06 +00:00
Ivan Lozano
eabde18653 Merge "rust: Add require_root and vendor install base" 2021-09-24 18:39:47 +00:00
Chris Parsons
a967f253e6 Add stl property support for bp2build
Test: mixed_libc
Test: USE_BAZEL_ANALYSIS=1 m libbase
Change-Id: If56d4a728de3ae4022cc9dadadc9bf8b952f9eaf
2021-09-24 13:51:56 -04:00
Liz Kammer
137044cac4 Merge "Refactor code for partitions c srcs" am: 46f8dbe06a
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1831493

Change-Id: Ib366e45228edca439c6dd41021945e0c62a7c127
2021-09-24 17:51:11 +00:00
Colin Cross
8304a1330e Add phony name for robolectric tests
Robolectric tests are installed by Soong, which means Make doesn't
know about the install location to create the phony rules.  Add
a phony rule in Soong for now until Soong's installation rules are
fleshed out.

Bug: 184946827
Test: m SettingsRoboTests
Change-Id: I60d76474949800e1a737714d86df84eff9a92214
2021-09-24 10:41:55 -07:00
Liz Kammer
46f8dbe06a Merge "Refactor code for partitions c srcs" 2021-09-24 17:35:16 +00:00
Paul Duffin
6369622f8d Add recovery image sdk trait to cc_library_headers
Allows an sdk to require that a cc_library_headers module provides a
recovery image variant for the prebuilt.

Previously, "recovery_available: true" would be set in the generated
prebuilt snapshot for any sdk member that specified
"recovery_available: true" in the source module. This change will only
add that setting to the snapshot if the recovery image variant trait
was explicitly requested for a member.

Bug: 195754365
Test: m nothing
Change-Id: I7d79ccdec843127f7852d82b4b163021e30a79a7
2021-09-24 17:44:37 +01:00
Paul Duffin
b42fa67a47 Insert imageVariantSpecificInfo between arch and link info
Previously, the archTypeSpecificInfo included an array of
*linkTypeSpecificInfo. This change replaces that array with an array of
*imageVariantSpecificInfo which themselves contain an array of
*linkTypeSpecificInfo.

That allows the sdk snapshot to handle image variants correctly, i.e.
collate their properties, optimize their properties and then detect if
there are any image variant specific properties for any image variant
other than the CoreImageVariant ("") and report it as an error.

The latter case is treated as an error because while Soong needs to
handle image specific variants there is currently no requirement to
handle generating a prebuilt with image specific properties. A follow
up change will test the error handling.

Image specific variants are needed because the "jni_headers"
cc_library_headers module provides a number of image variants (e.g.
recovery) that are used outside the ART module. Therefore, the sdk
snapshot needs to do the same.

At the moment image variants like the recovery variant are supported by
copying the property that creates the variant (e.g. recovery_available)
through to the prebuilt but that is not safe for a couple of reasons:
1. It ignores any differences between the recovery variant and the
   other variants which could cause compatibility issues in modules
   that build against the prebuilts.
2. It marks modules in the snapshot with recovery_available even when
   they do not need it.

This change will allow follow up changes to address both those issues.

Bug: 195754365
Test: m nothing
Change-Id: I1c187d814f44b2cb7607cd43a6b215134be0faad
2021-09-24 17:32:03 +01:00
Paul Duffin
b1f0f2aa80 Extract handling of image variations from target loop
This separates the selection of the image variations to depend upon
from the main target loop. Follow up changes will add additional
image variations.

Bug: 195754365
Test: m nothing
Change-Id: Ia1a61b1efbc96d92cb2faf1e2c4d1c5c752b8083
2021-09-24 17:15:40 +01:00
Liz Kammer
6fe2d9a3aa Merge "bp2build: Add support for export_.*headers props" am: 6244df2a24
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1835374

Change-Id: I10252c15de0bbc6691a69fb214461f6d56d000ff
2021-09-24 13:29:34 +00:00
Liz Kammer
6244df2a24 Merge "bp2build: Add support for export_.*headers props" 2021-09-24 13:13:05 +00:00
Treehugger Robot
374cc57731 Merge "Adding jdk.internal.misc in the allowed packages" am: f3c6843b33
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1734814

Change-Id: I44683dd3d82e28a6446e9e1278be99e3092e0f0b
2021-09-24 10:33:00 +00:00
Treehugger Robot
f3c6843b33 Merge "Adding jdk.internal.misc in the allowed packages" 2021-09-24 10:21:18 +00:00
Martin Stjernholm
40fc93fb3c Merge changes I957f3df8,I68986dcc am: cf6bf37d04
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1829372

Change-Id: Ifcf471f2746c1037b83c2a11b8f5120b86fd6cb2
2021-09-24 09:44:00 +00:00
Martin Stjernholm
cf6bf37d04 Merge changes I957f3df8,I68986dcc
* changes:
  Consolidate the code to resolve a deapexer module dependency.
  Propagate the dex jar path as an OptionalPath which is either valid or invalid with a message.
2021-09-24 09:32:24 +00:00
Jiakai Zhang
46eb0fd501 Remove updatable-bcp-packages.txt.
Historically, this file was used by the `--updatable-bcp-packages-file`
flag for dex2oat. The flag is no longer needed and is being deprecated.

Unfortunately, we cannot remove `permitted_packages` and all the code
related to it because we still need it for checking the module
compatibility with Q and R.

Bug: 200241946
Test: m nothing
Change-Id: Ie3be54fd47a847ba0caf627d12da76b415d99466
2021-09-24 03:19:05 +00:00
Treehugger Robot
d17a3ad9f2 Merge "For mixed build bazel actions, remove old outputs" am: e1bb74e724
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1834860

Change-Id: I32be5f8098a6161aad6d2bdabfb848fd374eeed1
2021-09-23 22:48:05 +00:00
Treehugger Robot
e1bb74e724 Merge "For mixed build bazel actions, remove old outputs" 2021-09-23 22:38:12 +00:00
Liz Kammer
57e2e7a78f Refactor code for partitions c srcs
To support protos (and other srcs that generate sources), we need to
partition further. Separate out into a separate common function.

Bug: 200601772
Test: build/bazel/ci/bp2build.sh
Change-Id: I7bf4cd96fd9a9fca4ccb3c96f21a04303201f891
2021-09-23 18:28:24 -04:00
Joel Galenson
8cbd0f5575 Merge "Pass "--extern proc_macro" to rust_proc_macros." am: 33e32f3ce5
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1834815

Change-Id: I4502f0468d3beef8d97b8e5fe134043f96b26cf9
2021-09-23 21:37:52 +00:00
Joel Galenson
33e32f3ce5 Merge "Pass "--extern proc_macro" to rust_proc_macros." 2021-09-23 21:26:22 +00:00
Chris Parsons
e37a4de773 For mixed build bazel actions, remove old outputs
This should fix incrementality issues in cases where actions don't wipe
the old output. (Looking at you, llvm-ar)

Test: mixed_libc.sh
Change-Id: I4b6639e74c72921a5a703d73fd36f766f121c6ad
2021-09-23 17:25:10 -04:00
Treehugger Robot
d5eadda1ee [automerger skipped] Merge "Changes tree built Robolectric name" am: 40660d21f8 -s ours
am skip reason: Merged-In If13583f6a2882e2e78d3004afc476debf6692df9 with SHA-1 69e65b3fcd is already in history

Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1817855

Change-Id: Ifcd614a7757c68d4ffa94ae370a06bad28df3963
2021-09-23 21:15:28 +00:00
Treehugger Robot
40660d21f8 Merge "Changes tree built Robolectric name" 2021-09-23 21:04:51 +00:00
Liz Kammer
7a210ac233 bp2build: Add support for export_.*headers props
Soong supports export_.*_headers properties, the libraries contained in
this list must also be within a shared/static/whole_static/header libs
property. For bp2build, we eliminate this duplication. The libraries
not listed in an export_.*_headers property will migrate to an attribute
prepended with implementation_, those in export_.*_headers will not have
a prefix.

Test: build/bazel/ci/bp2build.sh
Test: build/bazel/ci/mixed_libc.sh
Bug: 198241472
Change-Id: I3eb84c983ec5d241c8a568e411dfd5619d3184a7
2021-09-23 16:07:45 -04:00
Christopher Parsons
f75a32998e Merge "Disable mixed builds for non-device OS" am: 4ea6052650
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1834999

Change-Id: I7bdd47462db00faeaa85917d47f310c17b134aae
2021-09-23 20:02:36 +00:00
Christopher Parsons
4ea6052650 Merge "Disable mixed builds for non-device OS" 2021-09-23 19:45:15 +00:00
Ivan Lozano
18618ee803 Merge "rust: Refactor cfg and feature flag calculation" am: f96578e908
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1834996

Change-Id: I26e2d732f33128fee681728f3efb345179ec4485
2021-09-23 18:37:34 +00:00
Ivan Lozano
f96578e908 Merge "rust: Refactor cfg and feature flag calculation" 2021-09-23 18:25:22 +00:00
Wei Li
0e504d7dc9 Merge "Add bp2build converter for cc_genrule." am: a06db33ebd
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1829492

Change-Id: I73b0abd1f86d7dfc17a683595585aff4b5ffb91e
2021-09-23 18:17:04 +00:00
Chris Parsons
1826621bdd Disable mixed builds for non-device OS
We don't currently support propagation of OS in mixed builds, and our
host toolchains are not properly configured.

This allows us to continue to make progress on device OS until host is
supported.

Test: mixed_libc CI
Test: USE_BAZEL_ANALYSI=1 m adbd
Change-Id: I2bf8b3f9ca7928dd33bf2fb3d4fa067da0f593f3
2021-09-23 14:11:42 -04:00
Wei Li
a06db33ebd Merge "Add bp2build converter for cc_genrule." 2021-09-23 18:04:03 +00:00
Joel Galenson
ce7bbdc38a Pass "--extern proc_macro" to rust_proc_macros.
This is actually required for some code.

Test: Modify the new test so it fails and see it fail.
Test: Build crates that fail without it.
Change-Id: I527752b765e5552aa2de7e201f056955e053e1f3
2021-09-23 10:34:24 -07:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
0a72e89916 Merge "Annotate FIXME for b/200678898" am: fda604ab7c
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1832335

Change-Id: I73c2f65504a17a0b866ccb498ba1f20fcfd2b6f8
2021-09-23 17:22:51 +00:00
Christopher Parsons
f49703827f Merge "cquery: obtain objects from custom provider" am: 798e8876c8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1832977

Change-Id: I373d65ce6cda16e3a17c40e877d3b014271b0488
2021-09-23 17:22:40 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
fda604ab7c Merge "Annotate FIXME for b/200678898" 2021-09-23 17:18:49 +00:00
Christopher Parsons
798e8876c8 Merge "cquery: obtain objects from custom provider" 2021-09-23 17:11:25 +00:00
Sarah Chin
c1932a3b2b [automerger skipped] Merge "Add IRadio modules to VNDK" am: 1c0557ea82 -s ours
am skip reason: Merged-In Ia468b563c6485464db56b3c9cdbae80de6b3f165 with SHA-1 84fdadfe83 is already in history

Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1831864

Change-Id: Ic43251c71b59929cff7c52e12fbf156a51c2e675
2021-09-23 16:37:53 +00:00
Sarah Chin
1c0557ea82 Merge "Add IRadio modules to VNDK" 2021-09-23 16:35:42 +00:00
Ivan Lozano
67eada34db rust: Refactor cfg and feature flag calculation
Move the cfg and feature flag calculation out of compilerFlags so that
it's a separate step.

The previous arrangement resulted in overridden compilerFlags which
must to set any additional cfgs/features before calling the base.
This is a bit confusing and undocumented behavior, so instead break
it out into a separate call that can itself be overriden.

Bug: N/A
Test: Soong tests pass
Change-Id: I28e4f707b3b3ca6eb621b7613c3737817f877bb8
2021-09-23 12:21:04 -04:00
Martin Stjernholm
4482560cc7 Consolidate the code to resolve a deapexer module dependency.
It will get more logic in upcoming CLs.

Add a property to DeapexerInfo for the APEX name, for use in error
messages.

Test: m nothing
Bug: 192006406
Change-Id: I957f3df8b34543a38cde38768dac93e78132d672
2021-09-23 17:19:55 +01:00
Martin Stjernholm
8be1e6db16 Propagate the dex jar path as an OptionalPath which is either valid or
invalid with a message.

This will allow propagating any error from the deapexer module for
prebuilt APEXes to the location where the dex jars get used. It's only
at those points that we can raise errors about not being able to
extract files from the deapexer modules if they are invalid, and this
way we avoid encoding knowledge there about why they may be invalid.

To keep the refactoring limited it intentionally does not change any of
the existing logic for when dexJarFiles are set or not (non-nil vs nil
prior to this change), although there may be opportunity to use this
for more conditions when dex jars aren't available.

The refactoring is also not extended to
dexpreopt.ClassLoaderContextMap.

Test: m nothing
Bug: 192006406
Change-Id: I68986dccd9a9b3fee4d24caa1947ea17a36caedc
2021-09-23 17:19:55 +01:00
TreeHugger Robot
086cb94b7f Merge "Changes tree built Robolectric name" into stage-aosp-master 2021-09-23 15:58:22 +00:00
Alex Márquez Pérez Muñíz Díaz Púras Thaureaux
fd0c03c315 Annotate FIXME for b/200678898
Bug: 200678898
Test: TBD
Change-Id: I433f3187714d5ea19b081ed5e3fe758de0a29ddd
2021-09-23 15:12:03 +00:00
Chris Parsons
9eae3cb80e cquery: obtain objects from custom provider
This prevents use of CcInfo to obtain object information, as doing so
would mean propagating linker inputs transitively up the graph (not a
feature that Soong supports)

Test: mixed_libc.sh
Change-Id: I5e5cbfb607b866bb57491dbc0693f79b71707492
2021-09-23 11:01:52 -04:00
Treehugger Robot
f40148060b Merge changes I67c5022b,I3baa2535 am: 2e65f41953
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1832259

Change-Id: Idd0df37d03a2ac22c1e9e03a34cee680c4ad37c9
2021-09-23 14:37:07 +00:00