Commit Graph

43944 Commits

Author SHA1 Message Date
Paul Duffin
066500450b Merge "Extract preparer for namespace" am: bea17eff14 am: ea7b6c1184
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1761487

Change-Id: I6e1fe2b84341891c2fd249acc9399a9e60dd937e
2021-07-12 18:15:00 +00:00
Paul Duffin
ea7b6c1184 Merge "Extract preparer for namespace" am: bea17eff14
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1761487

Change-Id: Ie12de5c23280c133a4460fc5c814f04d91ac96f8
2021-07-12 17:56:12 +00:00
Paul Duffin
bea17eff14 Merge "Extract preparer for namespace" 2021-07-12 17:44:48 +00:00
Paul Duffin
cb049b6791 Move modules containing ART, conscrypt and i18n from libcore am: bb360c32b6 am: 9e36fa0eda
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1762226

Change-Id: I1c4579886602978ebc718a9a1ba36ad161d98697
2021-07-12 12:30:11 +00:00
Paul Duffin
9e36fa0eda Move modules containing ART, conscrypt and i18n from libcore am: bb360c32b6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1762226

Change-Id: Iea8772aa89c796255f264ff032698486974bbe7c
2021-07-12 12:17:10 +00:00
Martin Stjernholm
2e7d06fa5d [automerger skipped] Merge "Do not allow duplicate deapexer dependencies." into sc-dev am: 8410eb1551 -s ours
am skip reason: Merged-In Id2410b4e38a78ec2146a42298840954381a7c472 with SHA-1 1bc8412d37 is already in history

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

Change-Id: I9b9124c1b797b92a6481c5a3a128fedd59bd17df
2021-07-12 09:14:10 +00:00
Paul Duffin
bb360c32b6 Move modules containing ART, conscrypt and i18n from libcore
This change moves the definitions of the following libraries which
directly include ART, conscrypt and i18n stubs, and their associated
java_system_modules from libcore to build/soong/java/core-libraries.
* core.current.stubs
* core-current-stubs-system-modules
* core.module_lib.stubs
* core-module-lib-stubs-system-modules
* legacy.core.platform.api.stubs
* legacy-core-platform-api-stubs-system-modules
* stable.core.platform.api.stubs
* stable-core-platform-api-stubs-system-modules

Bug: 193311122
Test: m droid
Change-Id: I42c4a0b5322897d40ecf41de088152dbdc526c96
2021-07-12 10:10:42 +01:00
Martin Stjernholm
8410eb1551 Merge "Do not allow duplicate deapexer dependencies." into sc-dev 2021-07-12 09:01:43 +00:00
Paul Duffin
4fbfb59d3e Extract preparer for namespace
Bug: 193228441
Test: m nothing
Change-Id: If00b0595edd48be8c8d3308b87fb920dfb0340ee
2021-07-09 23:54:01 +01:00
Liz Kammer
7b6484325b Merge changes If89b7d0b,I630c06f0,Id861a62b,If71bb468 am: 1a0e2d20b3 am: 60cd3b9609
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1749407

Change-Id: I4346f2ae9432e2cd375bdbacb4a422105d73f3c5
2021-07-09 21:12:19 +00:00
Liz Kammer
60cd3b9609 Merge changes If89b7d0b,I630c06f0,Id861a62b,If71bb468 am: 1a0e2d20b3
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1749407

Change-Id: If50ef28db4d9d6e821119bf4ae669fd43c31bef5
2021-07-09 21:02:44 +00:00
Liz Kammer
1a0e2d20b3 Merge changes If89b7d0b,I630c06f0,Id861a62b,If71bb468
* changes:
  Iterate over sanitizers
  Update memtag code behavior to match comment.
  Reorganize memtag tests for clarity.
  Add comments to sanitizer properties.
2021-07-09 20:43:21 +00:00
Yuntao Xu
ed078ec058 Merge "modify cc_binary type to cc_test for test modules" am: ec04417506 am: 314e9e6423
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1758945

Change-Id: Ide151f9238ff7ebe09f77720231a3016209fe069
2021-07-09 17:17:24 +00:00
Yuntao Xu
314e9e6423 Merge "modify cc_binary type to cc_test for test modules" am: ec04417506
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1758945

Change-Id: I005a4d947eeb7123ab26ff1e0acc69db083e60c4
2021-07-09 16:55:53 +00:00
Yuntao Xu
ec04417506 Merge "modify cc_binary type to cc_test for test modules" 2021-07-09 16:38:11 +00:00
Yuntao Xu
8f884a0a69 modify cc_binary type to cc_test for test modules
1. When a cc_binary type module has the non-empty test_suites field,
modify the type to cc_test;
2. Unit tests were also added.

Bug: 193071602
Test: m androidmk
Test: TreeHugger
Change-Id: Icfaa79998616c02bb086f81d194163feafb4c116
2021-07-08 15:13:25 -07:00
Liz Kammer
75db931843 Iterate over sanitizers
Test: go test soong tests
Change-Id: If89b7d0b04cad79b42a08504d4fcff36e914b7a4
2021-07-08 11:19:15 -04:00
Liz Kammer
7b920b4057 Update memtag code behavior to match comment.
Test: go test soong tests
Change-Id: I630c06f01c90256b1990c37b9236e8967a5fa316
2021-07-08 11:19:15 -04:00
Liz Kammer
d56ddb5482 Reorganize memtag tests for clarity.
Test: go test soong tests
Change-Id: Id861a62bd0ff2b6a5a4354fbda939e9ebb13a2a5
2021-07-08 11:19:15 -04:00
Liz Kammer
75b9b40a56 Add comments to sanitizer properties.
Test: n/a
Change-Id: If71bb4683a4ae969670235c51b3f1b3af2073f91
2021-07-08 11:19:12 -04:00
Liz Kammer
acd1fb16d5 Merge changes I770f5ce7,I32d4417d am: 4aa48b03ea am: 1d9b80262e
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1749405

Change-Id: I21460aae0a59264de829322d6f1408c6322934ad
2021-07-08 13:39:51 +00:00
Liz Kammer
1d9b80262e Merge changes I770f5ce7,I32d4417d am: 4aa48b03ea
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1749405

Change-Id: Ifa7e1d2b6e3a8bcd2d0957ba1adc5bc302e32ce4
2021-07-08 13:26:23 +00:00
Liz Kammer
4aa48b03ea Merge changes I770f5ce7,I32d4417d
* changes:
  Remove IsDependencyRoot from interface
  Delete local boolPtr function
2021-07-08 13:11:17 +00:00
Treehugger Robot
1e3deb0500 Merge "Revert "Flag to control if generated SDK prebuilts are preferred."" am: af60f411f8 am: 968f5b4a73
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1758189

Change-Id: I357509cfd3801dfabafc5ff31a48c00303962e2b
2021-07-07 21:18:29 +00:00
Treehugger Robot
968f5b4a73 Merge "Revert "Flag to control if generated SDK prebuilts are preferred."" am: af60f411f8
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1758189

Change-Id: I21e7f7ebd3efa5ce11239068ef6989465809bb66
2021-07-07 21:05:34 +00:00
Treehugger Robot
af60f411f8 Merge "Revert "Flag to control if generated SDK prebuilts are preferred."" 2021-07-07 20:49:14 +00:00
Liz Kammer
187d5445e8 Remove IsDependencyRoot from interface
This is equivalent to Binary() -- reduce the interface and improve
clarity.

Test: go test soong tests
Change-Id: I770f5ce79fd4d888586d31ec5e67be88153626b6
2021-07-07 16:29:09 -04:00
Liz Kammer
b2fc4700de Delete local boolPtr function
This is defined in proptools, no need to duplicate.

Test: go test soong tests
Change-Id: I32d4417dc4ae73bff98f36360ed22aed572d8c18
2021-07-07 16:29:09 -04:00
Mathew Inwood
7e9ddbe8c8 Revert "Flag to control if generated SDK prebuilts are preferred."
This reverts commit d0b99cea0a.

Reason for revert: Not needed anymore. We will simple exclude the 
gernated Android.bp files from prebuilt drops instead, it keeps
things simpler.

Change-Id: I5b01b2e01197f9fceb4630c8ade95f0d1d0f33f4
2021-07-07 12:47:51 +00:00
Paul Duffin
fd44a2332a [automerger skipped] Merge "Generate boot images for host from prebuilts" into sc-dev am: d507060257 -s ours
am skip reason: Merged-In I6af00f19bb71aa18dd462f5eac6aa38e3e721023 with SHA-1 a56be7d781 is already in history

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

Change-Id: I5038caf149ee49a470ffdb553ea87693fc429259
2021-07-07 09:16:37 +00:00
Paul Duffin
931f0c0d6d [automerger skipped] Merge "Switch boot image generation to use GetGlobalSoongConfig(ctx)" into sc-dev am: 4ca4800023 -s ours
am skip reason: Merged-In I34b7b1526d072d8b09fda7caa96e381695888e16 with SHA-1 8fc51a8eb6 is already in history

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

Change-Id: I2dad85bed32f110242e53b8f56ea49102d9ff265
2021-07-07 09:16:32 +00:00
Paul Duffin
d507060257 Merge "Generate boot images for host from prebuilts" into sc-dev 2021-07-07 09:02:20 +00:00
Paul Duffin
4ca4800023 Merge "Switch boot image generation to use GetGlobalSoongConfig(ctx)" into sc-dev 2021-07-07 09:02:13 +00:00
TreeHugger Robot
a67adc98bb [automerger skipped] Merge changes from topic "revert-15071196-init_first_stage_soong-GBJXQRPEKC" into sc-dev am: 0618d4e9ec -s ours
am skip reason: Merged-In Ibc351645308676ed188f748972eb6312c9cbd64f with SHA-1 800d114003 is already in history. Merged-In was found from reverted change.

Reverted change: https://googleplex-android-review.googlesource.com/c/platform/build/soong/+/15067020

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

Change-Id: I7f62046303f71e08bf9363b56fe7bf052be06a6b
2021-07-07 03:18:00 +00:00
TreeHugger Robot
0618d4e9ec Merge changes from topic "revert-15071196-init_first_stage_soong-GBJXQRPEKC" into sc-dev
* changes:
  Revert "Add install_in_root to cc_binary"
  Revert "Add ramdisk_available to sysprop_library"
  Revert "Fix ndk and aml arch order"
2021-07-07 03:02:00 +00:00
Paul Duffin
6e89b54780 Generate boot images for host from prebuilts
Previously, when building from prebuilts boot no rules were created to
produce the boot image files for the host, i.e. the OS on which the
build was running. That caused problems with checkbuilds. No rules were
produced as there was no host variant of a prebuilt apex to provide
them.

This change restructures the code to allow the prebuilt bootclasspath
fragment to build the host variants of the files from the dex files
provided by the prebuilt APEX. The generated files will not be the same
as they would be if built from source as there is no boot image profile
to use but it should be sufficient to satisfy the checkbuild target and
allow for host side testing.

Bug: 192575099
Test: m SOONG_CONFIG_art_module_source_build=false droid dist checkbuild
Merged-In: I6af00f19bb71aa18dd462f5eac6aa38e3e721023
Change-Id: I6af00f19bb71aa18dd462f5eac6aa38e3e721023
(cherry picked from commit a56be7d781)
2021-07-06 22:20:24 +01:00
Paul Duffin
d564c32818 Switch boot image generation to use GetGlobalSoongConfig(ctx)
Previously, boot image generation used GetCachedGlobalSoongConfig(ctx)
in order to get access to the GlobalSoongConfig. That required that
some other part of the code had called GetGlobalSoongConfig(ctx) to
initialize the cached value. That was left over from when the boot
image generation was done in a singleton which could not call
GetGlobalSoongConfig(ctx) directly. That is no longer true.

This change switches the uses of GetCachedGlobalSoongConfig(ctx) to
GetGlobalSoongConfig(ctx) and removes the now unnecessary call to
GetGlobalSoongConfig(ctx) from outside the functions.

Bug: 192575099
Test: m nothing
Merged-In: I34b7b1526d072d8b09fda7caa96e381695888e16
Change-Id: I34b7b1526d072d8b09fda7caa96e381695888e16
(cherry picked from commit 8fc51a8eb6)
2021-07-06 22:20:24 +01:00
Paul Duffin
29abe2c894 [automerger skipped] Generate boot zip file from prebuilt_bootclasspath_fragment am: bb2e205603 -s ours
am skip reason: Merged-In Ie7dd5e2ca4a865d06fd9ebf87320cf68c4d05bc3 with SHA-1 56afb27fb0 is already in history

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

Change-Id: I204a72511ff9df3c7df3383dfe0afc40b234b7e6
2021-07-06 19:04:29 +00:00
Paul Duffin
803234f156 [automerger skipped] Use both module name and stem name to filter updatable boot jars am: aba5275676 -s ours
am skip reason: Merged-In I6c459fc3597b1e4f062bc9a4e52843305b538c5f with SHA-1 56c93e899a is already in history

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

Change-Id: Idc391ab80aa31d5bebe599c549d5f0f3541e87ef
2021-07-06 17:38:48 +00:00
Paul Duffin
b68c4c0b49 Generate boot images for host from prebuilts am: a56be7d781 am: 9dfd930cf7
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1757170

Change-Id: I2d343d227edb0b5138537f1fc3d36c4806340d51
2021-07-06 15:28:37 +00:00
Paul Duffin
9dfd930cf7 Generate boot images for host from prebuilts am: a56be7d781
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1757170

Change-Id: I21e0bd7ef439def519797f6a9e09857d23c9d276
2021-07-06 15:17:14 +00:00
Paul Duffin
688efcdbde Switch boot image generation to use GetGlobalSoongConfig(ctx) am: 8fc51a8eb6 am: 371276f582
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1757169

Change-Id: Ia5c95bfaf3a77614e15c1c5221826ed4c3d8abd8
2021-07-06 15:09:01 +00:00
Paul Duffin
371276f582 Switch boot image generation to use GetGlobalSoongConfig(ctx) am: 8fc51a8eb6
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1757169

Change-Id: I5cbc7fd0f5046031337afef2ec495088544f2438
2021-07-06 14:57:18 +00:00
Paul Duffin
a56be7d781 Generate boot images for host from prebuilts
Previously, when building from prebuilts boot no rules were created to
produce the boot image files for the host, i.e. the OS on which the
build was running. That caused problems with checkbuilds. No rules were
produced as there was no host variant of a prebuilt apex to provide
them.

This change restructures the code to allow the prebuilt bootclasspath
fragment to build the host variants of the files from the dex files
provided by the prebuilt APEX. The generated files will not be the same
as they would be if built from source as there is no boot image profile
to use but it should be sufficient to satisfy the checkbuild target and
allow for host side testing.

Bug: 192575099
Test: m SOONG_CONFIG_art_module_source_build=false droid dist checkbuild
Change-Id: I6af00f19bb71aa18dd462f5eac6aa38e3e721023
2021-07-06 13:45:46 +01:00
Paul Duffin
bb2e205603 Generate boot zip file from prebuilt_bootclasspath_fragment
Previously, the boot zip file, containing all the boot image files for
all the supported architectures, was only created from source. It was
not created when building from a prebuilt_bootclasspath_fragment. That
lead to build failures when building from ART prebuilts.

This change pulls the boot zip file creation out so that it can be done
for both source and prebuilt bootclasspath_fragment modules as well as
for the platform_bootclasspath module.

Bug: 192575099
Test: m out/target/product/generic_arm64/boot.zip
      m SOONG_CONFIG_art_module_source_build=false out/target/product/generic_arm64/boot.zip
      - Compare the output of the first command from before the change
        with the output from them both after and confirm that when the
        ART prebuilts are up to date with the source that there are no
        differences.
Merged-In: Ie7dd5e2ca4a865d06fd9ebf87320cf68c4d05bc3
Change-Id: Ie7dd5e2ca4a865d06fd9ebf87320cf68c4d05bc3
(cherry picked from commit 56afb27fb0)
2021-07-06 13:34:26 +01:00
Paul Duffin
aba5275676 Use both module name and stem name to filter updatable boot jars
Sometimes the stem property is set to change both the installed file
name and the name use to filter the configured module list, e.g. when
adding a test library to replace the standard library, e.g. test_foo
instead of foo.

Sometimes it is used just to change the installed file name.

This change uses both to filter the updatable boot jars and not just
the stem.

Bug: 180105615
Test: m nothing
Merged-In: I6c459fc3597b1e4f062bc9a4e52843305b538c5f
Change-Id: I6c459fc3597b1e4f062bc9a4e52843305b538c5f
(cherry picked from commit 56c93e899a)
2021-07-06 13:34:25 +01:00
Paul Duffin
8fc51a8eb6 Switch boot image generation to use GetGlobalSoongConfig(ctx)
Previously, boot image generation used GetCachedGlobalSoongConfig(ctx)
in order to get access to the GlobalSoongConfig. That required that
some other part of the code had called GetGlobalSoongConfig(ctx) to
initialize the cached value. That was left over from when the boot
image generation was done in a singleton which could not call
GetGlobalSoongConfig(ctx) directly. That is no longer true.

This change switches the uses of GetCachedGlobalSoongConfig(ctx) to
GetGlobalSoongConfig(ctx) and removes the now unnecessary call to
GetGlobalSoongConfig(ctx) from outside the functions.

Bug: 192575099
Test: m nothing
Change-Id: I34b7b1526d072d8b09fda7caa96e381695888e16
2021-07-06 12:51:04 +01:00
Pedro Loureiro
2f58789d65 make system server modules use filtered lint database am: 7609182dda
Original change: https://googleplex-android-review.googlesource.com/c/platform/build/soong/+/15208490

Change-Id: I4c93b1a85206124c7fd282e35904d5c55b7d0d59
2021-07-05 16:50:55 +00:00
Pedro Loureiro
7609182dda make system server modules use filtered lint database
Bug: 188851704
Test: m
Change-Id: Ie8f63286aeeb4cdbec5b9320c2ba41c8e37c7345
2021-07-05 14:01:49 +00:00
Paul Duffin
7ecb331fd3 Merge "Generate boot zip file from prebuilt_bootclasspath_fragment" am: 452decbd88 am: 019e278025
Original change: https://android-review.googlesource.com/c/platform/build/soong/+/1753271

Change-Id: I969dde3851899374bd466c9a0e5263f0fe6d12c8
2021-07-05 12:27:08 +00:00