diff options
Diffstat (limited to 'apex')
-rw-r--r-- | apex/vndk.go | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/apex/vndk.go b/apex/vndk.go index 3ececc5c1..5e630c0c0 100644 --- a/apex/vndk.go +++ b/apex/vndk.go @@ -20,6 +20,7 @@ import ( "android/soong/android" "android/soong/cc" + "github.com/google/blueprint" "github.com/google/blueprint/proptools" ) @@ -66,7 +67,14 @@ func apexVndkDepsMutator(mctx android.BottomUpMutatorContext) { vndkApexName := "com.android.vndk." + vndkVersion if mctx.OtherModuleExists(vndkApexName) { - mctx.AddReverseDependency(mctx.Module(), sharedLibTag, vndkApexName) + // Reverse dependencies must exactly specify the variant they want, starting from the + // current module's variant. But unlike cc modules, the vndk apex doesn't have + // arch/image/link variations, so we explicitly remove them here. + mctx.AddReverseVariationDependency([]blueprint.Variation{ + {Mutator: "arch", Variation: "common"}, + {Mutator: "image", Variation: ""}, + {Mutator: "link", Variation: ""}, + }, sharedLibTag, vndkApexName) } } else if a, ok := mctx.Module().(*apexBundle); ok && a.vndkApex { if a.IsNativeBridgeSupported() { |