summaryrefslogtreecommitdiff
path: root/rust/rust.go
diff options
context:
space:
mode:
author Ivan Lozano <ivanlozano@google.com> 2023-02-14 10:56:14 -0500
committer Ivan Lozano <ivanlozano@google.com> 2023-02-14 11:04:21 -0500
commit9ef9cb8b3f19e1d266863fe752bf168e8e35ffd4 (patch)
treea38b026685813dd5d7a258ffd5c700fa52b98e77 /rust/rust.go
parentda92c3ecbab21aceb03a1e008ba54484b8a6342c (diff)
rust: Fix coverage in no-std crates
Coverage builds for no_std crates currently fail because profiler_builtins are part of libstd and therefore do not get included. When calculating the dependencies for coverage enabled targets, check if the stdlib is being included, and if it is not then pull the profiler_builtins sysroot. Bug: 249551848 Test: CLANG_COVERAGE=true NATIVE_COVERAGE_PATHS='*' make libtinyvec_nostd.rlib-std Change-Id: I73f89bddcb2d4d9c704cb3962ee39b73888c7f3f
Diffstat (limited to 'rust/rust.go')
-rw-r--r--rust/rust.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/rust/rust.go b/rust/rust.go
index 67e0d7c03..e4cf67129 100644
--- a/rust/rust.go
+++ b/rust/rust.go
@@ -490,6 +490,7 @@ type compiler interface {
SetDisabled()
stdLinkage(ctx *depsContext) RustLinkage
+ noStdlibs() bool
unstrippedOutputFilePath() android.Path
strippedOutputFilePath() android.OptionalPath