summaryrefslogtreecommitdiff
path: root/rust/compiler.go
diff options
context:
space:
mode:
author Ivan Lozano <ivanlozano@google.com> 2021-04-14 19:02:49 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2021-04-14 19:02:49 +0000
commitd466b4a1f5ab2b1553bb3b6ed849e006713d9f31 (patch)
tree7b86cc8b71d47b03e1fce90bb179bb16dbbb0a4b /rust/compiler.go
parente8dfbdfb59ba807b809c368c604b684157747b46 (diff)
parentc08897c1e442be2e0f6db99ca310c9dc7c2e3194 (diff)
Merge changes from topic "rust_vendor_support"
* changes: Add more Rust vendor image support. rust: Use new common image mutator interface.
Diffstat (limited to 'rust/compiler.go')
-rw-r--r--rust/compiler.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/rust/compiler.go b/rust/compiler.go
index aaa192402..bc034d7cc 100644
--- a/rust/compiler.go
+++ b/rust/compiler.go
@@ -303,7 +303,6 @@ func (compiler *baseCompiler) compilerDeps(ctx DepsContext, deps Deps) Deps {
if ctx.Target().Os == android.BuildOs {
stdlib = stdlib + "_" + ctx.toolchain().RustTriple()
}
-
deps.Stdlibs = append(deps.Stdlibs, stdlib)
}
}
@@ -344,6 +343,10 @@ func (compiler *baseCompiler) installDir(ctx ModuleContext) android.InstallPath
if !ctx.Host() && ctx.Config().HasMultilibConflict(ctx.Arch().ArchType) {
dir = filepath.Join(dir, ctx.Arch().ArchType.String())
}
+
+ if compiler.location == InstallInData && ctx.RustModule().UseVndk() {
+ dir = filepath.Join(dir, "vendor")
+ }
return android.PathForModuleInstall(ctx, dir, compiler.subDir,
compiler.relativeInstallPath(), compiler.relative)
}