Skip to content

Commit e4bd5cd

Browse files
committed
Build dist-x86_64-musl with --enable-profiler.
Trying to build a Rust project with `-Zprofile` for target x86_64-unknown-linux-musl using rustc 1.46.0-nightly (346aec9 2020-07-11), installed with rustup, results in the following error. ``` export RUSTFLAGS="-Zprofile -Ccodegen-units=1 -Copt-level=0 -Clink-dead-code -Coverflow-checks=off -Zpanic_abort_tests -Cpanic=abort"export CARGO_INCREMENTAL=0$ cargo build --target=x86_64-unknown-linux-muslCompiling hello_world v0.1.0 (…)error[E0463]: can't find crate for `profiler_builtins` | = note: the compiler may have been built without the profiler runtime error: aborting due to previous error For more information about this error, try `rustc --explain E0463`.error: could not compile `hello_world`. To learn more, run the command again with --verbose. ``` `-Zprofile` is required here to enable grcov profiling. This is similar in nature to issue rust-lang#57257, which has been fixed in asimilar way at rust-lang#60476 . A fix for Android has also landed not long ago: rust-lang#70054 . Signed-off-by: Tiago Lam <[email protected]>
1 parent 3e3c552 commit e4bd5cd

File tree

1 file changed

+1
-0
lines changed
  • src/ci/docker/host-x86_64/dist-x86_64-musl

1 file changed

+1
-0
lines changed

src/ci/docker/host-x86_64/dist-x86_64-musl/Dockerfile

+1
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ ENV HOSTS=x86_64-unknown-linux-musl
3333
ENV RUST_CONFIGURE_ARGS \
3434
--musl-root-x86_64=/usr/local/x86_64-linux-musl \
3535
--enable-extended \
36+
--enable-profiler \
3637
--enable-lld \
3738
--set target.x86_64-unknown-linux-musl.crt-static=false \
3839
--build $HOSTS

0 commit comments

Comments
 (0)