Skip to content
Permalink
Browse files
rustc: Improve musl support
There was a slight error in the target logic I didn't notice before, and
also should do the same thing for the other platforms.
  • Loading branch information
Ericson2314 committed Nov 29, 2020
1 parent 7781642 commit f5f038127eafe83edb14df3fc464a1a4a0d93c7e
Showing with 5 additions and 1 deletion.
  1. +5 −1 pkgs/development/compilers/rust/rustc.nix
@@ -93,8 +93,12 @@ in stdenv.mkDerivation rec {
"${setTarget}.llvm-config=${llvmSharedForTarget}/bin/llvm-config"
] ++ optionals (stdenv.isLinux && !stdenv.targetPlatform.isRedox) [
"--enable-profiler" # build libprofiler_builtins
] ++ optionals stdenv.buildPlatform.isMusl [
"${setBuild}.musl-root=${pkgsBuildBuild.targetPackages.stdenv.cc.libc}"
] ++ optionals stdenv.hostPlatform.isMusl [
"${setHost}.musl-root=${pkgsBuildHost.targetPackages.stdenv.cc.libc}"
] ++ optionals stdenv.targetPlatform.isMusl [
"${setTarget}.musl-root=${targetPackages.stdenv.cc.libc}"
"${setTarget}.musl-root=${pkgsBuildTarget.targetPackages.stdenv.cc.libc}"
];

# The bootstrap.py will generated a Makefile that then executes the build.

0 comments on commit f5f0381

Please sign in to comment.