summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Treehugger Robot <treehugger-gerrit@google.com> 2019-11-04 02:00:41 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2019-11-04 02:00:41 +0000
commitf68f98eeb6374a865c8f40225eca7ca0cea46cad (patch)
treec1446601585b084922a54fd4357a1035e43bb10b
parentbb7c5d4f69d7c12a33e8ad5d2f8772ed1e035541 (diff)
parentbc093672ede984b2eede4e17add867a55db40738 (diff)
Merge "Fix vendor variants generation of vndk"
-rw-r--r--cc/cc.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/cc/cc.go b/cc/cc.go
index a312c49aa..5dfc56386 100644
--- a/cc/cc.go
+++ b/cc/cc.go
@@ -2653,7 +2653,11 @@ func ImageMutator(mctx android.BottomUpMutatorContext) {
// or a /system directory that is available to vendor.
coreVariantNeeded = true
vendorVariants = append(vendorVariants, platformVndkVersion)
- if m.IsVndk() {
+ // VNDK modules must not create BOARD_VNDK_VERSION variant because its
+ // code is PLATFORM_VNDK_VERSION.
+ // On the other hand, vendor_available modules which are not VNDK should
+ // also build BOARD_VNDK_VERSION because it's installed in /vendor.
+ if !m.IsVndk() {
vendorVariants = append(vendorVariants, deviceVndkVersion)
}
} else if vendorSpecific && String(m.Properties.Sdk_version) == "" {