Change occurrences of gcc to the more general cc

This is done for the sake of Yosemite, which does not have gcc, and yet
this change is also compatible with Linux.
This commit is contained in:
John Wiegley
2014-12-26 11:06:21 -06:00
parent ce100a5d58
commit 28b6fb61e6
252 changed files with 553 additions and 540 deletions
+2 -2
View File
@@ -167,8 +167,8 @@ stdenv.mkDerivation ({
configureScript="`pwd`/../$sourceRoot/configure"
${stdenv.lib.optionalString (stdenv.gcc.libc != null)
''makeFlags="$makeFlags BUILD_LDFLAGS=-Wl,-rpath,${stdenv.gcc.libc}/lib"''
${stdenv.lib.optionalString (stdenv.cc.libc != null)
''makeFlags="$makeFlags BUILD_LDFLAGS=-Wl,-rpath,${stdenv.cc.libc}/lib"''
}
${preConfigure}
+3 -3
View File
@@ -8,7 +8,7 @@
, withGd ? false, gd ? null, libpng ? null
}:
assert stdenv.gcc.gcc != null;
assert stdenv.cc ? gcc;
let
build = import ./common.nix;
@@ -33,9 +33,9 @@ in
# libgcc_s will not be at {gcc}/lib, and gcc's libgcc will be found without
# any special hack.
preInstall = ''
if [ -f ${stdenv.gcc.gcc}/lib/libgcc_s.so.1 ]; then
if [ -f ${stdenv.cc.gcc}/lib/libgcc_s.so.1 ]; then
mkdir -p $out/lib
cp ${stdenv.gcc.gcc}/lib/libgcc_s.so.1 $out/lib/libgcc_s.so.1
cp ${stdenv.cc.gcc}/lib/libgcc_s.so.1 $out/lib/libgcc_s.so.1
fi
'';