aboutsummaryrefslogtreecommitdiffstats
path: root/cc/vndk_prebuilt.go
diff options
context:
space:
mode:
authorJustin Yun <justinyun@google.com>2018-01-23 12:07:46 +0900
committerJustin Yun <justinyun@google.com>2018-01-24 07:52:47 +0900
commit312ccb974f953bc80867b4e32ddcd13ac9f9904d (patch)
tree1a39227f098450c162248de8de547b48d892e64a /cc/vndk_prebuilt.go
parentf231b19017e70f63991f7e0c822be08448942309 (diff)
downloadbuild_soong-312ccb974f953bc80867b4e32ddcd13ac9f9904d.tar.gz
build_soong-312ccb974f953bc80867b4e32ddcd13ac9f9904d.tar.bz2
build_soong-312ccb974f953bc80867b4e32ddcd13ac9f9904d.zip
Skip installing the VNDK prebuilt if arch does not match
For the VNDK prebuilt modules that does not match the target arch, skip installing the module instead of marking the module to prevent installing. Bug: 72310137 Bug: 71787263 Test: Install VNDK snapshot v27 lunch aosp_arm64_ab-userdebug; m vndk_v27_arm64 - vndk libs must be installed m vndk_v27_arm - no vndk libs must be installed because target does not match OUT_DIR=out_clean m --skip-make Change-Id: I9df25d90c276ce5e0d94ec7f9bee32f9ce7231df
Diffstat (limited to 'cc/vndk_prebuilt.go')
-rw-r--r--cc/vndk_prebuilt.go4
1 files changed, 4 insertions, 0 deletions
diff --git a/cc/vndk_prebuilt.go b/cc/vndk_prebuilt.go
index 99e35f34..9c9545d8 100644
--- a/cc/vndk_prebuilt.go
+++ b/cc/vndk_prebuilt.go
@@ -110,6 +110,10 @@ func (p *vndkPrebuiltLibraryDecorator) link(ctx ModuleContext,
}
func (p *vndkPrebuiltLibraryDecorator) install(ctx ModuleContext, file android.Path) {
+ arches := ctx.DeviceConfig().Arches()
+ if len(arches) == 0 || arches[0].ArchType.String() != p.arch() {
+ return
+ }
if p.shared() {
if ctx.isVndkSp() {
p.baseInstaller.subDir = "vndk-sp-" + p.version()