mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-20 12:42:24 +00:00
GCC 4.4: Fewer $NIX_ variables.
svn path=/nixpkgs/trunk/; revision=16458
This commit is contained in:
parent
685bb27c64
commit
292a191f70
|
@ -9,6 +9,11 @@ mkdir $NIX_FIXINC_DUMMY
|
|||
# Thing.
|
||||
export CPP="gcc -E"
|
||||
|
||||
if test "$staticCompiler" = "1"; then
|
||||
EXTRA_LDFLAGS="-static"
|
||||
else
|
||||
EXTRA_LDFLAGS=""
|
||||
fi
|
||||
|
||||
if test "$noSysDirs" = "1"; then
|
||||
|
||||
|
|
|
@ -57,8 +57,7 @@ stdenv.mkDerivation ({
|
|||
|
||||
patches =
|
||||
[./pass-cxxcpp.patch]
|
||||
++ optional noSysDirs ./no-sys-dirs.patch
|
||||
++ optional (noSysDirs && langFortran) ./no-sys-dirs-fortran.patch;
|
||||
++ optional noSysDirs ./no-sys-dirs.patch;
|
||||
|
||||
inherit noSysDirs profiledCompiler staticCompiler;
|
||||
|
||||
|
@ -91,8 +90,6 @@ stdenv.mkDerivation ({
|
|||
${if stdenv.isi686 then "--with-arch=i686" else ""}
|
||||
";
|
||||
|
||||
NIX_EXTRA_LDFLAGS = if staticCompiler then "-static" else "";
|
||||
|
||||
inherit gmp mpfr;
|
||||
|
||||
passthru = { inherit langC langCC langFortran langTreelang enableMultilib; };
|
||||
|
|
|
@ -1,15 +0,0 @@
|
|||
diff -ru gcc-4.3.1-orig/libgfortran/configure gcc-4.3.1/libgfortran/configure
|
||||
--- gcc-4.3.1-orig/libgfortran/configure 2008-06-06 16:49:11.000000000 +0200
|
||||
+++ gcc-4.3.1/libgfortran/configure 2008-06-27 08:25:08.000000000 +0200
|
||||
@@ -35405,6 +35405,11 @@
|
||||
# A language specific compiler.
|
||||
CC=$lt_compiler
|
||||
|
||||
+# Ugly hack to get libmudflap (and possibly other libraries) to build.
|
||||
+# Libtool filters out \`-B' flags when linking (why?), so the \`-B' flag
|
||||
+# to Glibc gets lost. Here we forcibly add it to any invocation.
|
||||
+CC="\$CC $NIX_EXTRA_CFLAGS $NIX_EXTRA_LDFLAGS"
|
||||
+
|
||||
# Is the compiler the GNU compiler?
|
||||
with_gcc=$GCC
|
||||
|
|
@ -64,69 +64,3 @@ diff -ru gcc-4.3.1-orig/gcc/Makefile.in gcc-4.3.1/gcc/Makefile.in
|
|||
-DCROSS_INCLUDE_DIR=\"$(CROSS_SYSTEM_HEADER_DIR)\" \
|
||||
-DTOOL_INCLUDE_DIR=\"$(gcc_tooldir)/include\" \
|
||||
-DPREFIX=\"$(prefix)/\" \
|
||||
diff -ru gcc-4.3.1-orig/libgomp/configure gcc-4.3.1/libgomp/configure
|
||||
--- gcc-4.3.1-orig/libgomp/configure 2008-01-24 17:23:13.000000000 +0100
|
||||
+++ gcc-4.3.1/libgomp/configure 2008-06-26 11:23:49.000000000 +0200
|
||||
@@ -21493,6 +21493,11 @@
|
||||
# A language specific compiler.
|
||||
CC=$lt_compiler
|
||||
|
||||
+# Ugly hack to get libmudflap (and possibly other libraries) to build.
|
||||
+# Libtool filters out \`-B' flags when linking (why?), so the \`-B' flag
|
||||
+# to Glibc gets lost. Here we forcibly add it to any invocation.
|
||||
+CC="\$CC $NIX_EXTRA_CFLAGS $NIX_EXTRA_LDFLAGS"
|
||||
+
|
||||
# Is the compiler the GNU compiler?
|
||||
with_gcc=$GCC
|
||||
|
||||
Only in gcc-4.3.1/libgomp: configure~
|
||||
diff -ru gcc-4.3.1-orig/libmudflap/configure gcc-4.3.1/libmudflap/configure
|
||||
--- gcc-4.3.1-orig/libmudflap/configure 2008-01-24 17:30:08.000000000 +0100
|
||||
+++ gcc-4.3.1/libmudflap/configure 2008-06-26 11:23:11.000000000 +0200
|
||||
@@ -14229,6 +14229,11 @@
|
||||
# A language specific compiler.
|
||||
CC=$lt_compiler
|
||||
|
||||
+# Ugly hack to get libmudflap (and possibly other libraries) to build.
|
||||
+# Libtool filters out \`-B' flags when linking (why?), so the \`-B' flag
|
||||
+# to Glibc gets lost. Here we forcibly add it to any invocation.
|
||||
+CC="\$CC $NIX_EXTRA_CFLAGS $NIX_EXTRA_LDFLAGS"
|
||||
+
|
||||
# Is the compiler the GNU compiler?
|
||||
with_gcc=$GCC
|
||||
|
||||
Only in gcc-4.3.1/libmudflap: configure~
|
||||
diff -ru gcc-4.3.1-orig/libssp/configure gcc-4.3.1/libssp/configure
|
||||
--- gcc-4.3.1-orig/libssp/configure 2008-01-24 17:33:29.000000000 +0100
|
||||
+++ gcc-4.3.1/libssp/configure 2008-06-26 11:23:25.000000000 +0200
|
||||
@@ -12142,6 +12142,11 @@
|
||||
# A language specific compiler.
|
||||
CC=$lt_compiler
|
||||
|
||||
+# Ugly hack to get libmudflap (and possibly other libraries) to build.
|
||||
+# Libtool filters out \`-B' flags when linking (why?), so the \`-B' flag
|
||||
+# to Glibc gets lost. Here we forcibly add it to any invocation.
|
||||
+CC="\$CC $NIX_EXTRA_CFLAGS $NIX_EXTRA_LDFLAGS"
|
||||
+
|
||||
# Is the compiler the GNU compiler?
|
||||
with_gcc=$GCC
|
||||
|
||||
Only in gcc-4.3.1/libssp: configure~
|
||||
diff -ru gcc-4.3.1-orig/Makefile.in gcc-4.3.1/Makefile.in
|
||||
--- gcc-4.3.1-orig/Makefile.in 2007-12-13 10:30:49.000000000 +0100
|
||||
+++ gcc-4.3.1/Makefile.in 2008-06-25 17:48:23.000000000 +0200
|
||||
@@ -405,6 +405,14 @@
|
||||
@host_makefile_frag@
|
||||
###
|
||||
|
||||
+CFLAGS += $(NIX_EXTRA_CFLAGS)
|
||||
+CPPFLAGS_FOR_TARGET += $(NIX_EXTRA_CFLAGS)
|
||||
+CXXFLAGS += $(NIX_EXTRA_CFLAGS)
|
||||
+LDFLAGS += $(NIX_EXTRA_LDFLAGS)
|
||||
+LDFLAGS_FOR_TARGET += $(NIX_EXTRA_LDFLAGS)
|
||||
+BOOT_CFLAGS += $(NIX_EXTRA_CFLAGS)
|
||||
+BOOT_LDFLAGS += $(NIX_EXTRA_LDFLAGS)
|
||||
+
|
||||
# This is the list of directories that may be needed in RPATH_ENVVAR
|
||||
# so that prorgams built for the target machine work.
|
||||
TARGET_LIB_PATH = $(TARGET_LIB_PATH_libstdc++-v3)$(TARGET_LIB_PATH_libmudflap)$(TARGET_LIB_PATH_libssp)$(TARGET_LIB_PATH_libgomp)$(HOST_LIB_PATH_gcc)
|
||||
|
|
Loading…
Reference in a new issue