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:
@@ -17,9 +17,11 @@ stdenv.mkDerivation rec {
|
||||
buildInputs = [ python bzip2 zlib gmp openssl boost ];
|
||||
|
||||
configurePhase = ''
|
||||
python configure.py --prefix=$out --with-gnump --with-bzip2 --with-zlib --with-openssl
|
||||
python configure.py --prefix=$out --with-gnump --with-bzip2 --with-zlib --with-openssl --cc=$CC
|
||||
'';
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
postInstall = ''
|
||||
cd "$out"/lib/pkgconfig
|
||||
ln -s botan-*.pc botan.pc || true
|
||||
|
||||
@@ -5,7 +5,7 @@ let
|
||||
bits = stdenv.lib.optionalString (stdenv.system == "x86_64-linux") "64";
|
||||
|
||||
libPath = stdenv.lib.makeLibraryPath
|
||||
[ stdenv.gcc.libc stdenv.gcc.gcc ] + ":${stdenv.gcc.gcc}/lib64";
|
||||
[ stdenv.cc.libc stdenv.cc.gcc ] + ":${stdenv.cc.gcc}/lib64";
|
||||
patchLib = x: "patchelf --set-rpath ${libPath} ${x}";
|
||||
in
|
||||
stdenv.mkDerivation rec {
|
||||
|
||||
@@ -35,8 +35,8 @@ stdenv.mkDerivation (rec {
|
||||
enableParallelBuilding = true;
|
||||
|
||||
crossAttrs = {
|
||||
buildInputs = stdenv.lib.optional (stdenv.gccCross.libc ? libiconv)
|
||||
stdenv.gccCross.libc.libiconv.crossDrv;
|
||||
buildInputs = stdenv.lib.optional (stdenv.ccCross.libc ? libiconv)
|
||||
stdenv.ccCross.libc.libiconv.crossDrv;
|
||||
# Gettext fails to guess the cross compiler
|
||||
configureFlags = "CXX=${stdenv.cross.config}-g++";
|
||||
};
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
with stdenv.lib;
|
||||
|
||||
assert stdenv.gcc.gcc != null;
|
||||
assert !stdenv.isDarwin -> stdenv.cc ? gcc;
|
||||
|
||||
# TODO:
|
||||
# * Add gio-module-fam
|
||||
@@ -83,7 +83,7 @@ stdenv.mkDerivation rec {
|
||||
preCheck = optionalString doCheck
|
||||
# libgcc_s.so.1 must be installed for pthread_cancel to work
|
||||
# also point to the glib/.libs path
|
||||
'' export LD_LIBRARY_PATH="${stdenv.gcc.gcc}/lib:$NIX_BUILD_TOP/${name}/glib/.libs:$LD_LIBRARY_PATH"
|
||||
'' export LD_LIBRARY_PATH="${stdenv.cc.gcc}/lib:$NIX_BUILD_TOP/${name}/glib/.libs:$LD_LIBRARY_PATH"
|
||||
export TZDIR="${tzdata}/share/zoneinfo"
|
||||
export XDG_CACHE_HOME="$TMP"
|
||||
export XDG_RUNTIME_HOME="$TMP"
|
||||
|
||||
@@ -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}
|
||||
|
||||
@@ -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
|
||||
'';
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ cabal.mkDerivation (self: {
|
||||
isLibrary = true;
|
||||
isExecutable = true;
|
||||
buildTools = [ c2hs ];
|
||||
extraLibraries = [ cudatoolkit nvidia_x11 self.stdenv.gcc ];
|
||||
extraLibraries = [ cudatoolkit nvidia_x11 self.stdenv.cc ];
|
||||
doCheck = false;
|
||||
# Perhaps this should be the default in cabal.nix ...
|
||||
#
|
||||
|
||||
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
|
||||
NROFF = "${groff}/bin/nroff";
|
||||
|
||||
postInstall = ''
|
||||
sed -i ${stdenv.lib.optionalString (stdenv.isDarwin && stdenv.gcc.nativeTools) "''"} s/-lncurses/-lncursesw/g $out/lib/pkgconfig/libedit.pc
|
||||
sed -i ${stdenv.lib.optionalString (stdenv.isDarwin && stdenv.cc.nativeTools) "''"} s/-lncurses/-lncursesw/g $out/lib/pkgconfig/libedit.pc
|
||||
'';
|
||||
|
||||
configureFlags = [ "--enable-widec" ];
|
||||
|
||||
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
|
||||
ar x opensc-dnie*
|
||||
tar xf data.tar.gz
|
||||
|
||||
RPATH=${glib}/lib:${opensc}/lib:${openssl}/lib:${openct}/lib:${libtool}/lib:${pcsclite}/lib:${stdenv.gcc.libc}/lib:${zlib}/lib
|
||||
RPATH=${glib}/lib:${opensc}/lib:${openssl}/lib:${openct}/lib:${libtool}/lib:${pcsclite}/lib:${stdenv.cc.libc}/lib:${zlib}/lib
|
||||
|
||||
for a in "usr/lib/"*.so*; do
|
||||
if ! test -L $a; then
|
||||
|
||||
@@ -11,8 +11,8 @@ stdenv.mkDerivation rec {
|
||||
"USE_ZLIB=1" "USE_OPENSSL=1"
|
||||
''PREFIX=$(out)''
|
||||
]
|
||||
++ stdenv.lib.optional (stdenv.gcc.gcc != null) "SYSROOT_ALT=${stdenv.gcc.gcc}"
|
||||
++ stdenv.lib.optional (stdenv.gcc.libc != null) "SYSROOT=${stdenv.gcc.libc}"
|
||||
++ stdenv.lib.optional (stdenv.cc.gcc != null) "SYSROOT_ALT=${stdenv.cc.gcc}"
|
||||
++ stdenv.lib.optional (stdenv.cc.libc != null) "SYSROOT=${stdenv.cc.libc}"
|
||||
;
|
||||
meta = {
|
||||
homepage = "http://www.creytiv.com/re.html";
|
||||
|
||||
@@ -12,8 +12,8 @@ stdenv.mkDerivation rec {
|
||||
"LIBRE_INC=${libre}/include/re"
|
||||
''PREFIX=$(out)''
|
||||
]
|
||||
++ stdenv.lib.optional (stdenv.gcc.gcc != null) "SYSROOT_ALT=${stdenv.gcc.gcc}"
|
||||
++ stdenv.lib.optional (stdenv.gcc.libc != null) "SYSROOT=${stdenv.gcc.libc}"
|
||||
++ stdenv.lib.optional (stdenv.cc.gcc != null) "SYSROOT_ALT=${stdenv.cc.gcc}"
|
||||
++ stdenv.lib.optional (stdenv.cc.libc != null) "SYSROOT=${stdenv.cc.libc}"
|
||||
;
|
||||
meta = {
|
||||
homepage = "http://www.creytiv.com/rem.html";
|
||||
|
||||
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
|
||||
inherit (s) url sha256;
|
||||
};
|
||||
preConfigure = ''
|
||||
sed -e 's@/usr/include/linux@${stdenv.gcc.libc}/include/linux@g' -i configure
|
||||
sed -e 's@/usr/include/linux@${stdenv.cc.libc}/include/linux@g' -i configure
|
||||
'';
|
||||
meta = {
|
||||
inherit (s) version;
|
||||
|
||||
@@ -21,6 +21,8 @@ stdenv.mkDerivation {
|
||||
sed -i 's|XPDF = xpdf_3.01|XPDF = ${libxpdf}/lib|' Makefile
|
||||
|
||||
mkdir exe
|
||||
|
||||
buildFlags+=" CXX=$CXX"
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
|
||||
@@ -11,12 +11,12 @@ stdenv.mkDerivation rec {
|
||||
|
||||
propagatedBuildInputs = [ zlib freetype libjpeg libtiff fontconfig openssl libpng ];
|
||||
nativeBuildInputs = [ cmake ];
|
||||
buildInputs = [ lua5 stdenv.gcc.libc ];
|
||||
buildInputs = [ lua5 stdenv.cc.libc ];
|
||||
|
||||
crossAttrs = {
|
||||
propagatedBuildInputs = [ zlib.crossDrv freetype.crossDrv libjpeg.crossDrv
|
||||
libtiff.crossDrv fontconfig.crossDrv openssl.crossDrv libpng.crossDrv
|
||||
lua5.crossDrv stdenv.gccCross.libc ];
|
||||
lua5.crossDrv stdenv.ccCross.libc ];
|
||||
};
|
||||
|
||||
# fix finding freetype-2.5
|
||||
|
||||
@@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
|
||||
# remove impure reference to /usr/lib/libstdc++.6.dylib
|
||||
# there might be more references, but this is the only one I could find
|
||||
substituteInPlace tools/macdeployqt/tests/tst_deployment_mac.cpp \
|
||||
--replace /usr/lib/libstdc++.6.dylib "${stdenv.gcc}/lib/libstdc++.6.dylib"
|
||||
--replace /usr/lib/libstdc++.6.dylib "${stdenv.cc}/lib/libstdc++.6.dylib"
|
||||
'';
|
||||
|
||||
patches =
|
||||
@@ -53,7 +53,7 @@ stdenv.mkDerivation rec {
|
||||
(substituteAll {
|
||||
src = ./dlopen-absolute-paths.diff;
|
||||
inherit cups icu libXfixes;
|
||||
glibc = stdenv.gcc.libc;
|
||||
glibc = stdenv.cc.libc;
|
||||
openglDriver = if mesaSupported then mesa.driverLink else "/no-such-path";
|
||||
})
|
||||
] ++ stdenv.lib.optional gtkStyle (substituteAll {
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{stdenv, fetchurl, patchelf, libusb}:
|
||||
|
||||
assert stdenv ? gcc && stdenv.gcc.libc != null;
|
||||
assert stdenv ? cc && stdenv.cc.libc != null;
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
name = "scmccid-5.0.11";
|
||||
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
|
||||
buildInputs = [ patchelf ];
|
||||
|
||||
installPhase = ''
|
||||
RPATH=${libusb}/lib:${stdenv.gcc.libc}/lib
|
||||
RPATH=${libusb}/lib:${stdenv.cc.libc}/lib
|
||||
|
||||
for a in proprietary/*/Contents/Linux/*.so*; do
|
||||
if ! test -L $a; then
|
||||
|
||||
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
|
||||
buildPhase = ''
|
||||
scons PREFIX="$out" OPENSSL="${openssl}" ZLIB="${zlib}" APR="$(echo "${apr}"/bin/*-config)" \
|
||||
APU="$(echo "${aprutil}"/bin/*-config)" GSSAPI="${krb5}" CC="${
|
||||
if stdenv.isDarwin then "clang" else "${stdenv.gcc}/bin/gcc"
|
||||
if stdenv.isDarwin then "clang" else "${stdenv.cc}/bin/gcc"
|
||||
}"
|
||||
'';
|
||||
|
||||
|
||||
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
|
||||
CLUCENE_HOME = clucene_core;
|
||||
|
||||
buildInputs =
|
||||
[ zlib bzip2 stdenv.gcc.libc libxml2 qt4 exiv2 clucene_core fam dbus_tools ];
|
||||
[ zlib bzip2 stdenv.cc.libc libxml2 qt4 exiv2 clucene_core fam dbus_tools ];
|
||||
|
||||
nativeBuildInputs = [ cmake pkgconfig perl ];
|
||||
|
||||
|
||||
@@ -57,8 +57,8 @@ stdenv.mkDerivation rec {
|
||||
'';
|
||||
|
||||
postFixup = if stdenv.isDarwin then ''
|
||||
install_name_tool -change /usr/local/lib/libv8.dylib $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.gcc.gcc}/lib/libgcc_s.1.dylib $out/bin/d8
|
||||
install_name_tool -id $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.gcc.gcc}/lib/libgcc_s.1.dylib $out/lib/libv8.dylib
|
||||
install_name_tool -change /usr/local/lib/libv8.dylib $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.cc.gcc}/lib/libgcc_s.1.dylib $out/bin/d8
|
||||
install_name_tool -id $out/lib/libv8.dylib -change /usr/lib/libgcc_s.1.dylib ${stdenv.cc.gcc}/lib/libgcc_s.1.dylib $out/lib/libv8.dylib
|
||||
'' else null;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
|
||||
@@ -22,6 +22,6 @@ for i in $libraries; do
|
||||
rpath=$rpath${rpath:+:}$i/lib
|
||||
done
|
||||
find $out -type f -perm +100 \
|
||||
-exec patchelf --interpreter "$(cat $NIX_GCC/nix-support/dynamic-linker)" {} \;
|
||||
-exec patchelf --interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" {} \;
|
||||
find $out -type f -perm +100 \
|
||||
-exec patchelf --set-rpath "$rpath" {} \;
|
||||
|
||||
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
|
||||
|
||||
buildInputs = [ unzip ];
|
||||
|
||||
libraries = [ xlibs.libXpm xlibs.libXt xlibs.libX11 xlibs.libICE xlibs.libSM stdenv.gcc.gcc ];
|
||||
libraries = [ xlibs.libXpm xlibs.libXt xlibs.libX11 xlibs.libICE xlibs.libSM stdenv.cc.gcc ];
|
||||
|
||||
meta = {
|
||||
homepage = http://java.sun.com/products/sjwtoolkit/download.html;
|
||||
|
||||
Reference in New Issue
Block a user