summaryrefslogtreecommitdiff
path: root/rust/compiler.go
diff options
context:
space:
mode:
authorJiyong Park <jiyong@google.com>2020-08-31 17:22:01 +0900
committerJiyong Park <jiyong@google.com>2020-09-15 12:56:13 +0900
commitb5d2dd210ba784429d10fb9ef8cfc20aabf57ec9 (patch)
tree7b98a3e2f14e66e721b941247fb9416e26f6836f /rust/compiler.go
parent4afa2e26828abf484f8d8e8355bc8eb1a30db2ae (diff)
Don't disable rust modules for linux_bionic
With If4300583edfb6d75bd4d984b38f73b6a406b4447, linux_bionic supports arm64 and rust toolchain was configured to support the new target. However, rust module types still have been disabled for linux_bionic targets which forces many rust modules to be annotated with target.linux_bionic_arm64.enabled: true, which will be very cumbersome. Therefore, stop disabling the rust modules for linux_bionic. Bug: 159685774 Test: HOST_CROSS_OS=linux_bionic m nothing Change-Id: I68b97a43e8252fb82da6e87b3481fa237e1f2691
Diffstat (limited to 'rust/compiler.go')
-rw-r--r--rust/compiler.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/rust/compiler.go b/rust/compiler.go
index ddf1fac3a..664578d82 100644
--- a/rust/compiler.go
+++ b/rust/compiler.go
@@ -216,8 +216,8 @@ func (compiler *baseCompiler) compilerDeps(ctx DepsContext, deps Deps) Deps {
if !Bool(compiler.Properties.No_stdlibs) {
for _, stdlib := range config.Stdlibs {
- // If we're building for the primary host target, use the compiler's stdlibs
- if ctx.Host() && ctx.TargetPrimary() {
+ // If we're building for the primary arch of the build host, use the compiler's stdlibs
+ if ctx.Target().Os == android.BuildOs && ctx.TargetPrimary() {
stdlib = stdlib + "_" + ctx.toolchain().RustTriple()
}