Commit graph

1612 commits

Author SHA1 Message Date
Treehugger Robot
53e5a32c18 Merge "Merge remote-tracking branch 'aosp/upstream'" am: e0118ca809 am: ec677dd8e0
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1449289

Change-Id: I97c6aded6a19c1d6822d90a825b09d6031fc0072
2020-10-07 13:03:19 +00:00
Treehugger Robot
ec677dd8e0 Merge "Merge remote-tracking branch 'aosp/upstream'" am: e0118ca809
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1449289

Change-Id: I83bf181436cabc09cca214d341e05be02dee5503
2020-10-07 12:47:52 +00:00
Treehugger Robot
e0118ca809 Merge "Merge remote-tracking branch 'aosp/upstream'" 2020-10-07 12:07:40 +00:00
colincross
25128bedbc
Merge pull request #325 from jin/codeowners
Add CODEOWNERS: @google/blueprint
2020-10-06 21:05:50 -07:00
Jingwen Chen
8a43c1bb1e Add CODEOWNERS: @google/blueprint 2020-10-07 11:57:54 +08:00
Liz Kammer
3132ba0096 Add blueprint owners: joeo, eakammer, patricearruda am: 18f643090f am: 4943ca6edc am: ff068dc94c
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1450855

Change-Id: Ia56660cbad518d9327bd8db25401df9e8b675fc4
2020-10-06 23:31:42 +00:00
Liz Kammer
ff068dc94c Add blueprint owners: joeo, eakammer, patricearruda am: 18f643090f am: 4943ca6edc
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1450855

Change-Id: Idf9ccb458b37ede0fde85d65a348f0402ea6e8d8
2020-10-06 23:05:35 +00:00
Liz Kammer
4943ca6edc Add blueprint owners: joeo, eakammer, patricearruda am: 18f643090f
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1450855

Change-Id: I9034ce9ee26e1c9b8fe68f6df3faaca0e347154b
2020-10-06 22:09:53 +00:00
Liz Kammer
18f643090f Add blueprint owners: joeo, eakammer, patricearruda
Change-Id: I1ec308a022b6a19cd4bd2fac24646862925c55e9
2020-10-06 08:42:52 -07:00
Liz Kammer
2aeb413fa1 Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Correct bug in generating anonymous nested props
  Add docs for nested and embedded structs

Test: m soong_docs
Change-Id: Ide95609b6c7d221037348768ade719992801e411
2020-10-05 15:12:03 -07:00
Liz Kammer
f20c9c3938
Merge pull request #324 from lizkammer/fix
Correct bug in generating anonymous nested props
2020-10-05 17:08:52 -05:00
Liz Kammer
2068e08a2c Correct bug in generating anonymous nested props
Some anonymous nested properties are missing from property structs,
since setting the property to anonymous is to allow future filtering,
there is no issue if we cannot find the struct.

test: go bpdoc tests
test: m soong_docs
2020-10-05 14:55:16 -07:00
Liz Kammer
a10477e361
Merge pull request #323 from lizkammer/bpdocs
Add docs for nested and embedded structs
2020-10-05 13:15:33 -05:00
Liz Kammer
5c9fe3834d Add docs for nested and embedded structs
Test: m soong_docs
Test: go bpdoc tests
Change-Id: I99f15405e1a7d4a819f6fb20fda22372afe253e1
2020-09-25 13:20:23 -07:00
Colin Cross
24843621ce Merge remote-tracking branch 'aosp/upstream' am: f94644fe3d am: ac49845522 am: a92993f52c am: 1cb0da0784
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1435711

Change-Id: I739961edf2b851ee40944478cb778e14f85133d9
2020-09-24 02:11:25 +00:00
Colin Cross
1cb0da0784 Merge remote-tracking branch 'aosp/upstream' am: f94644fe3d am: ac49845522 am: a92993f52c
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1435711

Change-Id: Ib4c684a8f42bf10dc3c6788f76a0cfd8752153cd
2020-09-24 01:25:00 +00:00
Colin Cross
a92993f52c Merge remote-tracking branch 'aosp/upstream' am: f94644fe3d am: ac49845522
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1435711

Change-Id: Ia8f8e01f5fe6a57452393a403456acd2323f9a00
2020-09-24 01:08:28 +00:00
Colin Cross
ac49845522 Merge remote-tracking branch 'aosp/upstream' am: f94644fe3d
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1435711

Change-Id: Ic6ae040cfffe1db9523751a0c4740a39b20b6561
2020-09-24 00:49:50 +00:00
Colin Cross
f94644fe3d Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Add Providers to Blueprint

Test: m checkbuild
Change-Id: I4d722c70ce347b16e6258ecd4c3df3adc9d17035
2020-09-23 10:40:18 -07:00
colincross
8a747a0864
Merge pull request #309 from colincross/providers
Add Providers to Blueprint
2020-09-23 10:27:40 -07:00
Colin Cross
2da8492b9d Add Providers to Blueprint
Providers are a new concept for Blueprint, based on providers in Bazel:
https://docs.bazel.build/versions/master/skylark/rules.html#providers

Providers aim to simplify the interaction between modules by replacing
type asserting to arbitrary interfaces with requesting optional data
objects from modules.  This will also move Blueprint closer to supporting
incremental analysis by serializing the providers and only rerunning
the analysis phase on modules whose inputs have changed.

Change-Id: I39f5f78b372412a7dbf151ceccb3f917f6c874bf
2020-09-22 18:20:18 -07:00
Colin Cross
4f969f8f19 Merge remote-tracking branch 'aosp/upstream' am: f38eda59a8 am: e09f8a48e8 am: a5923ae3e1 am: c14bf7ad42
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1434328

Change-Id: Ib6cf2f1021c8ca8801d3364afe766a62f2f81f6f
2020-09-23 01:08:04 +00:00
Colin Cross
c14bf7ad42 Merge remote-tracking branch 'aosp/upstream' am: f38eda59a8 am: e09f8a48e8 am: a5923ae3e1
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1434328

Change-Id: I2e9dff4a330ea8fa785606fa6d2fbeb478a12187
2020-09-23 00:24:07 +00:00
Colin Cross
a5923ae3e1 Merge remote-tracking branch 'aosp/upstream' am: f38eda59a8 am: e09f8a48e8
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1434328

Change-Id: I08783e9c51c0e7b4357fd306395a1654119c0130
2020-09-23 00:06:47 +00:00
Colin Cross
e09f8a48e8 Merge remote-tracking branch 'aosp/upstream' am: f38eda59a8
Original change: https://android-review.googlesource.com/c/platform/build/blueprint/+/1434328

Change-Id: I887667972e15d635b54e6f17b89fa5d9a399096f
2020-09-22 23:51:08 +00:00
Colin Cross
f38eda59a8 Merge remote-tracking branch 'aosp/upstream'
* aosp/upstream:
  Return dependency modules from dependency-adding methods.
  Support pausing parallelVisit

Test: m checkbuild
Change-Id: I5a01454e5d66d8fe00ef2f363d0fcbcfcee9fef9
2020-09-22 11:05:03 -07:00
colincross
66fa73dd6e
Merge pull request #316 from skvadrik/add-dep-ret-mod
Return dependency modules from dependency-adding methods.
2020-09-22 10:59:46 -07:00
colincross
ca601ee4fb
Merge pull request #318 from colincross/pause_parallel_visit
Support pausing parallelVisit
2020-09-22 10:58:03 -07:00
Ulya Trafimovich
9577bbc922 Return dependency modules from dependency-adding methods.
The motivaion for this change is to allow writing code that uses the
newly added dependency module in the same mutator pass, for example to
add more dependencies. Like this:

  for _, m := range ctx.AddVariationDependencies(nil, tag, deps...) {
      if someModuleProperty(m); ok {
          ctx.AddVariationDependencies(nil, tag, otherDep)
      }
  }

Note that there is no guarantee that the returned module has already
been processed by the current mutator.

The patch does not add runtime overhead on findng dependency modules,
as this has already been done previously.

Test: go test
2020-09-17 11:43:15 +01:00
Colin Cross
c4773d90a2 Support pausing parallelVisit
Pass a channel to visitor functions called by parallelVisit that
allows them to pause the current visitor until a given visitor
has finished.  This allows parallelVisit to work on a dependency
graph while it is being mutated.

Test: Test_parallelVisit
Change-Id: Id8b1542c22ac9914439310e31d992ae0d7318d69
2020-09-16 12:58:39 -07:00
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