Commit graph

1482 commits

Author SHA1 Message Date
Colin Cross
50094b1dd5 Merge remote-tracking branch 'aosp/upstream' am: 60bb204d8f am: a488647fa1 am: a7e0531213 am: a44090a3c1
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1426208

Change-Id: I66549f1f476a3ab4ac694e6f2b21eb7e946bf7d8
2020-09-12 22:26:39 +00:00
Colin Cross
a44090a3c1 Merge remote-tracking branch 'aosp/upstream' am: 60bb204d8f am: a488647fa1 am: a7e0531213
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1426208

Change-Id: I70dd28746bb4df287672180c59810f4ab496cf72
2020-09-12 22:04:49 +00:00
Colin Cross
a7e0531213 Merge remote-tracking branch 'aosp/upstream' am: 60bb204d8f am: a488647fa1
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1426208

Change-Id: Ic798a46aef22f8a5be4cb712c910a12e6535a4a2
2020-09-12 21:19:52 +00:00
Colin Cross
a488647fa1 Merge remote-tracking branch 'aosp/upstream' am: 60bb204d8f
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1426208

Change-Id: I117257f1aede6eadf39c96cc4e45f961bdc0aabf
2020-09-12 20:49:33 +00:00
Colin Cross
60bb204d8f Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Relax check in moduleMatchingVariant
  Fix AddFarVariationDependencies subset checks
  Maintain ordering between variants and aliases
  Add tests for findVariant

Test: m checkbuild
Change-Id: I4c166ff93a09fe4c6d700c82f79548f0b4afdae0
2020-09-11 20:20:41 -07:00
colincross
4b3efdc5b8
Merge pull request #321 from colincross/far_variations
Relax check in moduleMatchingVariant
2020-09-11 20:15:21 -07:00
Colin Cross
edbdb8c2d3 Relax check in moduleMatchingVariant
Pull request #317 made the equality check in moduleMatchingVariant
more correct by comparing the variant maps instead of the names.
Using only the names effectively ignores any variation with an
empty name.  Unfortuantely this broke a current user of
ReplaceDependenciesIf.  Go back to the relaxed check for now.

Test: build on a branch with sdk modules
Change-Id: I11016c8df7bd91fd022d04fd3033756f54d7fa0b
2020-09-11 19:24:59 -07:00
colincross
277bac9904
Merge pull request #317 from colincross/far_variations
Fix AddFarVariationDependencies
2020-09-11 14:57:09 -07:00
Colin Cross
e3acf9a010 Merge remote-tracking branch 'aosp/upstream' am: 8dfb36edbf am: a95771e79b am: a8aa969bda am: 7e7b0e574b
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1423970

Change-Id: I081c8188682e2dfb1353155ded00f694e8aef076
2020-09-11 04:57:09 +00:00
Colin Cross
7e7b0e574b Merge remote-tracking branch 'aosp/upstream' am: 8dfb36edbf am: a95771e79b am: a8aa969bda
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1423970

Change-Id: I3bf0ec2492e0510ce7a9c549b2d91cc89ba253ee
2020-09-11 03:48:56 +00:00
Colin Cross
a8aa969bda Merge remote-tracking branch 'aosp/upstream' am: 8dfb36edbf am: a95771e79b
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1423970

Change-Id: I32ecb427a7cab1eb0180a61b032bdb6ba661bcc5
2020-09-11 02:15:58 +00:00
Colin Cross
a95771e79b Merge remote-tracking branch 'aosp/upstream' am: 8dfb36edbf
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1423970

Change-Id: I59fbed77481b5e6a9e4f9726c80e0969327a9f50
2020-09-11 01:01:05 +00:00
Colin Cross
5dc6759951 Fix AddFarVariationDependencies subset checks
AddFarVariationDependencies claims to take the first variant that
matches all the requested variations, but it did nothing of the sort.
It took the first variant that either matched or did not contain each
of the requested variations.  A module with no variations was always
matched, and requesting variations that didn't apply to a module
still matched (for example, requesting an image variation for a
host module that was ignored by the image mutator).

Fix AddFarVariationDependencies by making subset actually check
for subsets.

Test: Test_findVariant
Change-Id: I10063fec342db2a1c0685a7db08e4a650d14bd4e
2020-09-09 18:29:15 -07:00
Colin Cross
5df74a8e38 Maintain ordering between variants and aliases
AddFarVariationDependencies takes the first matching variant.  To
maintain sensible behavior on a module with aliases, the ordering
of aliases and module variants needs to be maintained so that
AddFarVariationDependencies can find an earlier matching alias
instead of a more specific variant.

Test: go test .
Change-Id: I78f4e96edd98159f3a62d94e240e5d652667bec4
2020-09-09 18:29:15 -07:00
Colin Cross
39644c0903 Add tests for findVariant
Add tests for findVariant behavior that provides the matching
behaviors of AddVariationDependencies, AddFarVariationDependencies,
etc.

Test: Test_findVariant
Change-Id: I3494d57179c8b3d62f7d32e5a1b43c9b9672c2df
2020-09-09 18:27:32 -07:00
Colin Cross
8dfb36edbf Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Enable variants of bootstrap modules
  Make VisitAllModuleVariants, PrimaryModule and FinalModule available to mutators
  bpmodify: handle nested properties

Test: m checkbuild
Change-Id: I9785802ed33fa819b705317cd50c38432972e94c
2020-09-09 15:18:51 -07:00
colincross
ad63e18efe
Merge pull request #320 from colincross/bootstrap_variants
Enable variants of bootstrap modules
2020-09-09 15:01:12 -07:00
Colin Cross
d2458a23bf Enable variants of bootstrap modules
The primary builder may want to create variants of bootstrap
modules if they need to fit in to the primary builder's dependency
graph.  Enable arbitrary variants of bootstrap modules by only
running the module's actions on the primary variant and then
copying the result to any other variants that exist.

Test: m checkbuild
Change-Id: I24b97771bb11faeacab4079ed8cf69aef59da140
2020-09-09 14:32:42 -07:00
Colin Cross
18926521dc Make VisitAllModuleVariants, PrimaryModule and FinalModule available to mutators
Move the VisitAllModuleVariants, PrimaryModule and FinalModule methods to
baseModuleContext so they can be used by mutators.

Test: m checkbuild
Change-Id: I1827ce2fc75f017460a7f6a53b1dab6a81109435
2020-09-09 13:25:54 -07:00
Dan Willemsen
34e8ddd0a5
Merge pull request #294 from silverneko/master
bpmodify: handle nested properties
2020-09-02 17:28:12 -07:00
Xin Li
bd50ea7434 [automerger skipped] Mark Android R (rvc-dev-plus-aosp-without-vendor@6692709) as merged am: 32feafd96e -s ours am: b57ad7abad -s ours am: 4b58ee1624 -s ours
am skip reason: Change-Id I0b10c9cb0b11dfa1677b16e472a26208932d4c08 with SHA-1 b06c753d91 is in history

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

Change-Id: I81b72883f7cead42a55bc8f7037567ab70b3c29d
2020-08-27 19:12:37 +00:00
Xin Li
4b58ee1624 [automerger skipped] Mark Android R (rvc-dev-plus-aosp-without-vendor@6692709) as merged am: 32feafd96e -s ours am: b57ad7abad -s ours
am skip reason: Change-Id I0b10c9cb0b11dfa1677b16e472a26208932d4c08 with SHA-1 b06c753d91 is in history

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

Change-Id: Id898d3dc53345a92090f4709567db31906a7c86c
2020-08-27 18:54:19 +00:00
Xin Li
b57ad7abad [automerger skipped] Mark Android R (rvc-dev-plus-aosp-without-vendor@6692709) as merged am: 32feafd96e -s ours
am skip reason: Change-Id I0b10c9cb0b11dfa1677b16e472a26208932d4c08 with SHA-1 b06c753d91 is in history

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

Change-Id: I64dbdd2440f4a00f008e5b2b734438bed2ada603
2020-08-27 18:23:25 +00:00
Xin Li
32feafd96e Mark Android R (rvc-dev-plus-aosp-without-vendor@6692709) as merged
Bug: 166295507
Merged-In: I0b10c9cb0b11dfa1677b16e472a26208932d4c08
Change-Id: I6e1add57781b620195e34a7feae07c1e82996a9f
2020-08-27 09:44:04 -07:00
Colin Cross
ecb20f0ef6 Merge remote-tracking branch 'aosp/upstream' am: ce522b4826 am: ba9a3b9ea8 am: 849f77de00 am: 8b295a293c
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1401130

Change-Id: Ia3a670c6c20324aa3c3f79c55b6b15e264d30e98
2020-08-14 23:28:42 +00:00
Colin Cross
8b295a293c Merge remote-tracking branch 'aosp/upstream' am: ce522b4826 am: ba9a3b9ea8 am: 849f77de00
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1401130

Change-Id: I64bc633f4980e387f2cecbdc2b751d2338d4c549
2020-08-14 23:19:59 +00:00
Colin Cross
849f77de00 Merge remote-tracking branch 'aosp/upstream' am: ce522b4826 am: ba9a3b9ea8
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1401130

Change-Id: Ib41fa8c63d6178081aeb03790e3ce2497da9dc4d
2020-08-14 23:13:01 +00:00
Colin Cross
ba9a3b9ea8 Merge remote-tracking branch 'aosp/upstream' am: ce522b4826
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1401130

Change-Id: Ib14cd39cef93cefdcbcb78564767b936c77856af
2020-08-14 23:00:02 +00:00
Colin Cross
ce522b4826 Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Add CreateAliasVariation
  Combine variant fields into variant struct

Bug: 164216768
Test: m checkbuild
Change-Id: Ie46adc27a7af6a35803f2189ed7dbc154de79541
2020-08-14 14:05:56 -07:00
colincross
bc973ffe1e
Merge pull request #314 from colincross/alias_variations
Add CreateAliasVariation
2020-08-14 13:47:14 -07:00
Colin Cross
279489c017 Add CreateAliasVariation
CreateAliasVariation creates a new variation for the current mutator
that is an alias to a variation that was created with CreateVarations
by the same mutator.  It is similar to AliasVariation, except that
AliasVariation creates an alias from the pre-mutated variant to one
of the new variations, while CreateAliasVariation creates an alias
from a new post-mutated variation to one of the new variations.

Bug: 164216768
Test: TestCreateAliasVariation
Change-Id: I8847b8d6fc1d3248abc910b2fe2399881f9bdaee
2020-08-14 11:15:58 -07:00
Colin Cross
edc41769fe Combine variant fields into variant struct
Combine variant, variations and dependencyVariations into a single
struct.

Test: blueprint tests
Change-Id: I76811bb2bdf76f1b4cffc6a7b9bc7362ecb5f7b9
2020-08-14 11:15:58 -07:00
Colin Cross
443197c803 Merge remote-tracking branch 'aosp/upstream' into inclusive am: c69182870e am: ec4ae78c09 am: 4914fd7bc8 am: e66d914238
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1380886

Change-Id: Icfda8b0fb1677bb8a4699865339f42dc34baf69f
2020-08-06 20:49:45 +00:00
Colin Cross
e66d914238 Merge remote-tracking branch 'aosp/upstream' into inclusive am: c69182870e am: ec4ae78c09 am: 4914fd7bc8
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1380886

Change-Id: I0141ea62d861386a41228583f02d5306b7d13511
2020-08-06 20:28:18 +00:00
Colin Cross
4914fd7bc8 Merge remote-tracking branch 'aosp/upstream' into inclusive am: c69182870e am: ec4ae78c09
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1380886

Change-Id: I5f711b44855aa14fb6f2b3f60818b8b5124bbef1
2020-08-06 20:16:03 +00:00
Colin Cross
ec4ae78c09 Merge remote-tracking branch 'aosp/upstream' into inclusive am: c69182870e
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1380886

Change-Id: I5ca3261464e85a1bcf413f6d9fa5addee84f39e1
2020-08-06 20:06:02 +00:00
Colin Cross
c69182870e Merge remote-tracking branch 'aosp/upstream' into inclusive
* aosp/upstream:
  Android inclusive language fixit.  Make comment more succinct, clear and remove use of term "sanity".
  Update bpdocs to filter nested properties by tags (#312)

Bug: 162536543
Test: m checkbuild
Change-Id: I4b40b1637e142d2f2fd513f62357213a9832bbaa
2020-07-30 17:28:24 -07:00
colincross
576b0fd577
Merge pull request #313 from colincross/inclusive
Android inclusive language fixit.  Make comment more succinct, clear …
2020-07-30 16:51:50 -07:00
Daniel Cardenas
5de3dc04e0 Android inclusive language fixit. Make comment more succinct, clear and remove use of term "sanity".
Bug: 162536543
Change-Id: I4b40b1637e142d2f2fd513f62357213a9832bbaa
2020-07-30 16:48:42 -07:00
Liz Kammer
9810dcd4b9
Update bpdocs to filter nested properties by tags (#312)
* Update bpdocs to filter nested properties by tag

Prior to this change nested properties tagged with `blueprint:"mutated"`
are erroneously included in documentation, this corrects that behavior
and adds testing to verify.

Tested: go test bpdocs tests
Change-Id: I822c9a98276634d2f584d8709e83003824cdffd5
2020-07-28 09:30:46 -07:00
Colin Cross
6cd7bdef6e Merge remote-tracking branch 'aosp/upstream' am: 9b15d1a888 am: d5cf2cb6be am: b06c753d91 am: e70176d3ef
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1364798

Change-Id: I2b86633dfe54ad9d2b531886fa667918a8e98e9e
2020-07-16 23:02:15 +00:00
Colin Cross
e70176d3ef Merge remote-tracking branch 'aosp/upstream' am: 9b15d1a888 am: d5cf2cb6be am: b06c753d91
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1364798

Change-Id: I5622ef0aa718f42bd910995bb69139077c13801f
2020-07-16 22:44:08 +00:00
Colin Cross
b06c753d91 Merge remote-tracking branch 'aosp/upstream' am: 9b15d1a888 am: d5cf2cb6be
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1364798

Change-Id: I0b10c9cb0b11dfa1677b16e472a26208932d4c08
2020-07-16 22:25:46 +00:00
Colin Cross
d5cf2cb6be Merge remote-tracking branch 'aosp/upstream' am: 9b15d1a888
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1364798

Change-Id: I9fcc87af3d45dcc134e8b32cacbab1d0157448dc
2020-07-16 22:08:46 +00:00
Colin Cross
9b15d1a888 Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Add flag to use validations for tests
  Add Validations support to Blueprint
  Remove unused Context.ModulePath

Test: m checkbuild
Change-Id: Ib63d651e79801121681dff449136067d1ea3b321
2020-07-16 13:00:57 -07:00
colincross
94594808c5
Merge pull request #308 from colincross/modulepath
Remove unused Context.ModulePath
2020-07-16 12:54:17 -07:00
colincross
ab003ffcee
Merge pull request #311 from colincross/validations
Add Validations support to Blueprint
2020-07-09 19:20:01 -07:00
Colin Cross
0cdec99c81 Add flag to use validations for tests
Using validations for tests ensures the tests run without blocking
the critical path.

Change-Id: Icb21a52e96f70d815f7df86882351c13f5575cf5
2020-07-09 14:28:20 -07:00
Colin Cross
9ece72b055 Add Validations support to Blueprint
The Android fork of Ninja supports "validations", a node that is
added to the top level of the build graph whenever another node
is in the build graph.  Add support in Blueprint to specify them
on build statements and write them to the ninja.

Test: ninja_writer_test.go
Change-Id: I87cd1281dbd2ed113cc26a265c50d20c65118c91
2020-07-09 14:28:20 -07:00
Colin Cross
f0f5c6e591 Merge remote-tracking branch 'aosp/upstream' am: 726d2e6085 am: 8ea9686962 am: e9e15a5059 am: d16010a154
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1354383

Change-Id: Idecdb4e4797bf2a687c8a8364d38503aca957b1e
2020-07-08 18:55:11 +00:00