summaryrefslogtreecommitdiff
path: root/rust/binary.go
diff options
context:
space:
mode:
authorIvan Lozano <ivanlozano@google.com>2020-07-24 16:05:01 -0400
committerIvan Lozano <ivanlozano@google.com>2020-07-28 14:53:57 -0400
commit45901edb9a6ba7b42136a3ead126f94f76363eb7 (patch)
treeb5270f6d6fd3889442b77c32f9d8153cd7d388b2 /rust/binary.go
parente1e844b83cb37c72bf233034c3985a69f71e2e9d (diff)
Ensure hermetic device rust_bindgen.
rust_bindgen was not hermetic previously as it would pull in host headers for device targets. This fixes that by using the same flags we use when compiling with Clang. This also makes sure our rust_bindgen headers are built as similar as possible to their respective cc_libraries. This also pulls in the bionic dependencies as well, which provide the headers required for device targets. Bug: 162007475 Test: device rust_bindgen deps file does not reference host headers. Change-Id: I4efdf333e011a6c6d73a0345e5485823f166d17a
Diffstat (limited to 'rust/binary.go')
-rw-r--r--rust/binary.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/rust/binary.go b/rust/binary.go
index 48f51dbdf..0d7f541c9 100644
--- a/rust/binary.go
+++ b/rust/binary.go
@@ -86,7 +86,7 @@ func (binary *binaryDecorator) compilerDeps(ctx DepsContext, deps Deps) Deps {
deps = binary.baseCompiler.compilerDeps(ctx, deps)
if ctx.toolchain().Bionic() {
- deps = binary.baseCompiler.bionicDeps(ctx, deps)
+ deps = bionicDeps(deps)
deps.CrtBegin = "crtbegin_dynamic"
deps.CrtEnd = "crtend_android"
}