mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-21 11:34:13 +00:00
Merge pull request #105383 from NixOS/more-rustc-musl
rustc: Improve musl support
This commit is contained in:
commit
68fa053f46
@ -1,5 +1,4 @@
|
|||||||
{ stdenv, removeReferencesTo, pkgsBuildBuild, pkgsBuildHost, pkgsBuildTarget
|
{ stdenv, removeReferencesTo, pkgsBuildBuild, pkgsBuildHost, pkgsBuildTarget
|
||||||
, targetPackages
|
|
||||||
, fetchurl, file, python3
|
, fetchurl, file, python3
|
||||||
, llvm_10, darwin, cmake, rust, rustPlatform
|
, llvm_10, darwin, cmake, rust, rustPlatform
|
||||||
, pkgconfig, openssl
|
, pkgconfig, openssl
|
||||||
@ -93,8 +92,12 @@ in stdenv.mkDerivation rec {
|
|||||||
"${setTarget}.llvm-config=${llvmSharedForTarget}/bin/llvm-config"
|
"${setTarget}.llvm-config=${llvmSharedForTarget}/bin/llvm-config"
|
||||||
] ++ optionals (stdenv.isLinux && !stdenv.targetPlatform.isRedox) [
|
] ++ optionals (stdenv.isLinux && !stdenv.targetPlatform.isRedox) [
|
||||||
"--enable-profiler" # build libprofiler_builtins
|
"--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 [
|
] ++ 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.
|
# The bootstrap.py will generated a Makefile that then executes the build.
|
||||||
|
Loading…
Reference in New Issue
Block a user