mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-11-15 13:37:21 +03:00
GCC 4.5: Use install-strip' instead of
-Wl,--strip-debug'; add `gcc45_debug'.
svn path=/nixpkgs/branches/stdenv-updates/; revision=26467
This commit is contained in:
parent
3e71355377
commit
d887437d8e
@ -47,7 +47,7 @@ if test "$noSysDirs" = "1"; then
|
||||
fi
|
||||
|
||||
extraFlags="-g0 -O2 -I$NIX_FIXINC_DUMMY $extraFlags"
|
||||
extraLDFlags="--strip-debug -L$glibc_libdir -rpath $glibc_libdir $extraLDFlags"
|
||||
extraLDFlags="-L$glibc_libdir -rpath $glibc_libdir $extraLDFlags"
|
||||
|
||||
EXTRA_FLAGS="$extraFlags"
|
||||
for i in $extraLDFlags; do
|
||||
@ -90,7 +90,7 @@ if test "$noSysDirs" = "1"; then
|
||||
glibc_libdir="$(cat $NIX_GCC_CROSS/nix-support/orig-libc)/lib"
|
||||
|
||||
extraFlags="-g0 -O2 -I$NIX_FIXINC_DUMMY_CROSS $extraFlags"
|
||||
extraLDFlags="--strip-debug -L$glibc_libdir -rpath $glibc_libdir $extraLDFlags"
|
||||
extraLDFlags="-L$glibc_libdir -rpath $glibc_libdir $extraLDFlags"
|
||||
|
||||
EXTRA_TARGET_CFLAGS="$extraFlags"
|
||||
for i in $extraLDFlags; do
|
||||
|
@ -26,6 +26,7 @@
|
||||
, crossStageStatic ? true
|
||||
, gnat ? null
|
||||
, libpthread ? null, libpthreadCross ? null # required for GNU/Hurd
|
||||
, stripped ? true
|
||||
}:
|
||||
|
||||
assert langTreelang -> bison != null && flex != null;
|
||||
@ -259,6 +260,11 @@ stdenv.mkDerivation ({
|
||||
|
||||
targetConfig = if (cross != null) then cross.config else null;
|
||||
|
||||
installTargets =
|
||||
if stripped
|
||||
then "install-strip"
|
||||
else "install";
|
||||
|
||||
crossAttrs = {
|
||||
AR = "${stdenv.cross.config}-ar";
|
||||
LD = "${stdenv.cross.config}-ld";
|
||||
@ -364,7 +370,8 @@ stdenv.mkDerivation ({
|
||||
meta = {
|
||||
homepage = http://gcc.gnu.org/;
|
||||
license = "GPLv3+"; # runtime support libraries are typically LGPLv3+
|
||||
description = "GNU Compiler Collection, version ${version}";
|
||||
description = "GNU Compiler Collection, version ${version}"
|
||||
+ (if stripped then "" else " (with debugging info)");
|
||||
|
||||
longDescription = ''
|
||||
The GNU Compiler Collection includes compiler front ends for C, C++,
|
||||
@ -392,6 +399,8 @@ stdenv.mkDerivation ({
|
||||
installTargets = "install-gcc install-target-libgcc";
|
||||
}
|
||||
|
||||
// optionalAttrs (!stripped) { dontStrip = true; NIX_STRIP_DEBUG = false; }
|
||||
|
||||
// optionalAttrs langVhdl rec {
|
||||
name = "ghdl-0.29";
|
||||
|
||||
|
@ -1670,6 +1670,20 @@ let
|
||||
profiledCompiler = if stdenv.system == "armv5tel-linux" then false else true;
|
||||
}));
|
||||
|
||||
# A non-stripped version of GCC.
|
||||
gcc45_debug = lowPrio (wrapGCC (callPackage ../development/compilers/gcc-4.5 {
|
||||
stripped = false;
|
||||
|
||||
inherit noSysDirs;
|
||||
cross = null;
|
||||
libcCross = null;
|
||||
binutilsCross = null;
|
||||
|
||||
# bootstrapping a profiled compiler does not work in the sheevaplug:
|
||||
# http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43944
|
||||
profiledCompiler = if stdenv.system == "armv5tel-linux" then false else true;
|
||||
}));
|
||||
|
||||
gccApple =
|
||||
wrapGCC ( (if stdenv.system == "i686-darwin" then import ../development/compilers/gcc-apple else import ../development/compilers/gcc-apple64) {
|
||||
inherit fetchurl stdenv noSysDirs;
|
||||
|
Loading…
Reference in New Issue
Block a user