Merge pull request #19198 from acowley/rustc-darwin
rustc: fix build on darwin
This commit is contained in:
commit
008344b29a
|
@ -92,6 +92,13 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
# Useful debugging parameter
|
# Useful debugging parameter
|
||||||
# export VERBOSE=1
|
# export VERBOSE=1
|
||||||
|
'' +
|
||||||
|
# In src/compiler-rt/cmake/config-ix.cmake, the cmake build falls
|
||||||
|
# back to darwin 10.4. This causes the OS name to be recorded as
|
||||||
|
# "10.4" rather than the expected "osx". But mk/rt.mk expects the
|
||||||
|
# built library name to have an "_osx" suffix on darwin.
|
||||||
|
optionalString stdenv.isDarwin ''
|
||||||
|
substituteInPlace mk/rt.mk --replace "_osx" "_10.4"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
|
@ -118,7 +125,13 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
preCheck = ''
|
preCheck = ''
|
||||||
export TZDIR=${tzdata}/share/zoneinfo
|
export TZDIR=${tzdata}/share/zoneinfo
|
||||||
${optionalString stdenv.isDarwin "export TMPDIR=/tmp"}
|
'' +
|
||||||
|
# Ensure TMPDIR is set, and disable a test that removing the HOME
|
||||||
|
# variable from the environment falls back to another home
|
||||||
|
# directory.
|
||||||
|
optionalString stdenv.isDarwin ''
|
||||||
|
export TMPDIR=/tmp
|
||||||
|
sed -i '28s/home_dir().is_some()/true/' ./src/test/run-pass/env-home-dir.rs
|
||||||
'';
|
'';
|
||||||
|
|
||||||
# Disable doCheck on Darwin to work around upstream issue
|
# Disable doCheck on Darwin to work around upstream issue
|
||||||
|
|
Loading…
Reference in New Issue