Bp2build support for soong config variables + os
For converting the art plugins to pure soong, it would be useful to
have a property that's qualified on both a soong config variable and
the OS. Soong had very little-known support for this by saying your
soong config variable changes the "target.android.cflags" property,
and we didn't supporting bp2building that. Add the bp2build support.
This cl also refactors product variable and soong variable bp2building
so that they're separate from each other, which I think makes the code
easier to understand.
Test: go test
Change-Id: Ic74dc75da8103fa2523da95c3560c9ce3c5e5672
diff --git a/bazel/properties.go b/bazel/properties.go
index 1757bad..77db1c4 100644
--- a/bazel/properties.go
+++ b/bazel/properties.go
@@ -334,7 +334,7 @@
if containsArch {
allProductVariablesAreArchVariant := true
for k := range la.ConfigurableValues {
- if k.configurationType == productVariables && k.outerAxisType != arch {
+ if k.configurationType == productVariables && !k.archVariant {
allProductVariablesAreArchVariant = false
}
}