mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-06 04:27:27 +03:00
gcc-*: homogenize and cleanup expressions without a rebuild
Looks scary but it is a noop.
This commit is contained in:
parent
87c0206038
commit
e0b5919197
@ -52,12 +52,9 @@ with builtins;
|
|||||||
|
|
||||||
let version = "4.8.5";
|
let version = "4.8.5";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches = [ ]
|
patches = [ ../parallel-bconfig.patch ]
|
||||||
++ optional enableParallelBuilding ../parallel-bconfig.patch
|
|
||||||
++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
|
++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
|
||||||
++ optional noSysDirs ../no-sys-dirs.patch
|
++ optional noSysDirs ../no-sys-dirs.patch
|
||||||
++ optional langFortran ../gfortran-driving.patch
|
++ optional langFortran ../gfortran-driving.patch
|
||||||
@ -175,14 +172,14 @@ stdenv.mkDerivation ({
|
|||||||
|
|
||||||
inherit patches;
|
inherit patches;
|
||||||
|
|
||||||
hardeningDisable = [ "format" ];
|
|
||||||
|
|
||||||
outputs = [ "out" "lib" "man" "info" ];
|
outputs = [ "out" "lib" "man" "info" ];
|
||||||
setOutputFlags = false;
|
setOutputFlags = false;
|
||||||
NIX_NO_SELF_RPATH = true;
|
NIX_NO_SELF_RPATH = true;
|
||||||
|
|
||||||
libc_dev = stdenv.cc.libc_dev;
|
libc_dev = stdenv.cc.libc_dev;
|
||||||
|
|
||||||
|
hardeningDisable = [ "format" ];
|
||||||
|
|
||||||
postPatch =
|
postPatch =
|
||||||
if targetPlatform != hostPlatform || stdenv.cc.libc != null then
|
if targetPlatform != hostPlatform || stdenv.cc.libc != null then
|
||||||
# On NixOS, use the right path to the dynamic linker instead of
|
# On NixOS, use the right path to the dynamic linker instead of
|
||||||
@ -209,8 +206,9 @@ stdenv.mkDerivation ({
|
|||||||
++ (optional (perl != null) perl)
|
++ (optional (perl != null) perl)
|
||||||
++ (optional javaAwtGtk pkgconfig);
|
++ (optional javaAwtGtk pkgconfig);
|
||||||
|
|
||||||
buildInputs = [ gmp mpfr libmpc libelf ]
|
buildInputs = [
|
||||||
++ (optional (cloog != null) cloog)
|
gmp mpfr libmpc libelf
|
||||||
|
] ++ (optional (cloog != null) cloog)
|
||||||
++ (optional (isl != null) isl)
|
++ (optional (isl != null) isl)
|
||||||
++ (optional (zlib != null) zlib)
|
++ (optional (zlib != null) zlib)
|
||||||
++ (optionals langJava [ boehmgc zip unzip ])
|
++ (optionals langJava [ boehmgc zip unzip ])
|
||||||
@ -222,7 +220,6 @@ stdenv.mkDerivation ({
|
|||||||
++ (optional hostPlatform.isDarwin gnused)
|
++ (optional hostPlatform.isDarwin gnused)
|
||||||
;
|
;
|
||||||
|
|
||||||
|
|
||||||
preConfigure = stdenv.lib.optionalString (hostPlatform.isSunOS && hostPlatform.is64bit) ''
|
preConfigure = stdenv.lib.optionalString (hostPlatform.isSunOS && hostPlatform.is64bit) ''
|
||||||
export NIX_LDFLAGS=`echo $NIX_LDFLAGS | sed -e s~$prefix/lib~$prefix/lib/amd64~g`
|
export NIX_LDFLAGS=`echo $NIX_LDFLAGS | sed -e s~$prefix/lib~$prefix/lib/amd64~g`
|
||||||
export LDFLAGS_FOR_TARGET="-Wl,-rpath,$prefix/lib/amd64 $LDFLAGS_FOR_TARGET"
|
export LDFLAGS_FOR_TARGET="-Wl,-rpath,$prefix/lib/amd64 $LDFLAGS_FOR_TARGET"
|
||||||
@ -354,13 +351,13 @@ stdenv.mkDerivation ({
|
|||||||
++ optional (zlib != null) zlib
|
++ optional (zlib != null) zlib
|
||||||
++ optional langJava boehmgc
|
++ optional langJava boehmgc
|
||||||
++ optionals javaAwtGtk xlibs
|
++ optionals javaAwtGtk xlibs
|
||||||
++ optionals javaAwtGtk [ gmp mpfr ])
|
++ optionals javaAwtGtk [ gmp mpfr ]
|
||||||
);
|
));
|
||||||
|
|
||||||
EXTRA_TARGET_FLAGS = optionals
|
EXTRA_TARGET_FLAGS = optionals
|
||||||
(targetPlatform != hostPlatform && libcCross != null)
|
(targetPlatform != hostPlatform && libcCross != null)
|
||||||
([
|
([
|
||||||
"-idirafter ${libcCross.dev}/include"
|
"-idirafter ${getDev libcCross}/include"
|
||||||
] ++ optionals (! crossStageStatic) [
|
] ++ optionals (! crossStageStatic) [
|
||||||
"-B${libcCross.out}/lib"
|
"-B${libcCross.out}/lib"
|
||||||
]);
|
]);
|
||||||
@ -382,7 +379,8 @@ stdenv.mkDerivation ({
|
|||||||
hardeningUnsupportedFlags = [ "stackprotector" ];
|
hardeningUnsupportedFlags = [ "stackprotector" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{ stdenv, targetPackages, fetchurl, noSysDirs, fetchpatch
|
{ stdenv, targetPackages, fetchurl, fetchpatch, noSysDirs
|
||||||
, langC ? true, langCC ? true, langFortran ? false
|
, langC ? true, langCC ? true, langFortran ? false
|
||||||
, langObjC ? stdenv.targetPlatform.isDarwin
|
, langObjC ? stdenv.targetPlatform.isDarwin
|
||||||
, langObjCpp ? stdenv.targetPlatform.isDarwin
|
, langObjCpp ? stdenv.targetPlatform.isDarwin
|
||||||
@ -52,13 +52,10 @@ with builtins;
|
|||||||
|
|
||||||
let version = "4.9.4";
|
let version = "4.9.4";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
[ ../use-source-date-epoch.patch ]
|
[ ../use-source-date-epoch.patch ../parallel-bconfig.patch ./parallel-strsignal.patch ]
|
||||||
++ optionals enableParallelBuilding [ ../parallel-bconfig.patch ./parallel-strsignal.patch ]
|
|
||||||
++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
|
++ optional (targetPlatform != hostPlatform) ../libstdc++-target.patch
|
||||||
++ optional noSysDirs ../no-sys-dirs.patch
|
++ optional noSysDirs ../no-sys-dirs.patch
|
||||||
++ optional langFortran ../gfortran-driving.patch
|
++ optional langFortran ../gfortran-driving.patch
|
||||||
@ -183,8 +180,6 @@ stdenv.mkDerivation ({
|
|||||||
|
|
||||||
inherit patches;
|
inherit patches;
|
||||||
|
|
||||||
hardeningDisable = [ "format" ];
|
|
||||||
|
|
||||||
outputs = if langJava || langGo then ["out" "man" "info"]
|
outputs = if langJava || langGo then ["out" "man" "info"]
|
||||||
else [ "out" "lib" "man" "info" ];
|
else [ "out" "lib" "man" "info" ];
|
||||||
setOutputFlags = false;
|
setOutputFlags = false;
|
||||||
@ -192,6 +187,8 @@ stdenv.mkDerivation ({
|
|||||||
|
|
||||||
libc_dev = stdenv.cc.libc_dev;
|
libc_dev = stdenv.cc.libc_dev;
|
||||||
|
|
||||||
|
hardeningDisable = [ "format" ];
|
||||||
|
|
||||||
postPatch =
|
postPatch =
|
||||||
if targetPlatform != hostPlatform || stdenv.cc.libc != null then
|
if targetPlatform != hostPlatform || stdenv.cc.libc != null then
|
||||||
# On NixOS, use the right path to the dynamic linker instead of
|
# On NixOS, use the right path to the dynamic linker instead of
|
||||||
@ -250,8 +247,7 @@ stdenv.mkDerivation ({
|
|||||||
''
|
''
|
||||||
+ stdenv.lib.optionalString (langJava || langGo) ''
|
+ stdenv.lib.optionalString (langJava || langGo) ''
|
||||||
export lib=$out;
|
export lib=$out;
|
||||||
''
|
'';
|
||||||
;
|
|
||||||
|
|
||||||
dontDisableStatic = true;
|
dontDisableStatic = true;
|
||||||
|
|
||||||
@ -376,7 +372,8 @@ stdenv.mkDerivation ({
|
|||||||
++ optional (zlib != null) zlib
|
++ optional (zlib != null) zlib
|
||||||
++ optional langJava boehmgc
|
++ optional langJava boehmgc
|
||||||
++ optionals javaAwtGtk xlibs
|
++ optionals javaAwtGtk xlibs
|
||||||
++ optionals javaAwtGtk [ gmp mpfr ]));
|
++ optionals javaAwtGtk [ gmp mpfr ]
|
||||||
|
));
|
||||||
|
|
||||||
EXTRA_TARGET_FLAGS = optionals
|
EXTRA_TARGET_FLAGS = optionals
|
||||||
(targetPlatform != hostPlatform && libcCross != null)
|
(targetPlatform != hostPlatform && libcCross != null)
|
||||||
@ -397,10 +394,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -424,7 +424,8 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
stdenv.lib.platforms.illumos;
|
stdenv.lib.platforms.illumos ++
|
||||||
|
stdenv.lib.platforms.darwin;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -49,9 +49,6 @@ with stdenv.lib;
|
|||||||
with builtins;
|
with builtins;
|
||||||
|
|
||||||
let version = "5.5.0";
|
let version = "5.5.0";
|
||||||
sha256 = "11zd1hgzkli3b2v70qsm2hyqppngd4616qc96lmm9zl2kl9yl32k";
|
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
@ -164,7 +161,7 @@ stdenv.mkDerivation ({
|
|||||||
|
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url = "mirror://gnu/gcc/gcc-${version}/gcc-${version}.tar.xz";
|
url = "mirror://gnu/gcc/gcc-${version}/gcc-${version}.tar.xz";
|
||||||
inherit sha256;
|
sha256 = "11zd1hgzkli3b2v70qsm2hyqppngd4616qc96lmm9zl2kl9yl32k";
|
||||||
};
|
};
|
||||||
|
|
||||||
inherit patches;
|
inherit patches;
|
||||||
@ -397,10 +394,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -424,6 +424,7 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
|
stdenv.lib.platforms.illumos ++
|
||||||
stdenv.lib.platforms.darwin;
|
stdenv.lib.platforms.darwin;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -50,8 +50,6 @@ with builtins;
|
|||||||
|
|
||||||
let version = "6.4.0";
|
let version = "6.4.0";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
@ -257,8 +255,7 @@ stdenv.mkDerivation ({
|
|||||||
''
|
''
|
||||||
+ stdenv.lib.optionalString (langJava || langGo) ''
|
+ stdenv.lib.optionalString (langJava || langGo) ''
|
||||||
export lib=$out;
|
export lib=$out;
|
||||||
''
|
'';
|
||||||
;
|
|
||||||
|
|
||||||
dontDisableStatic = true;
|
dontDisableStatic = true;
|
||||||
|
|
||||||
@ -380,7 +377,8 @@ stdenv.mkDerivation ({
|
|||||||
++ optional (zlib != null) zlib
|
++ optional (zlib != null) zlib
|
||||||
++ optional langJava boehmgc
|
++ optional langJava boehmgc
|
||||||
++ optionals javaAwtGtk xlibs
|
++ optionals javaAwtGtk xlibs
|
||||||
++ optionals javaAwtGtk [ gmp mpfr ]));
|
++ optionals javaAwtGtk [ gmp mpfr ]
|
||||||
|
));
|
||||||
|
|
||||||
EXTRA_TARGET_FLAGS = optionals
|
EXTRA_TARGET_FLAGS = optionals
|
||||||
(targetPlatform != hostPlatform && libcCross != null)
|
(targetPlatform != hostPlatform && libcCross != null)
|
||||||
@ -401,10 +399,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -428,6 +429,7 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
|
stdenv.lib.platforms.illumos ++
|
||||||
stdenv.lib.platforms.darwin;
|
stdenv.lib.platforms.darwin;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -39,8 +39,6 @@ with builtins;
|
|||||||
|
|
||||||
let version = "7.3.0";
|
let version = "7.3.0";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
@ -344,10 +342,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -371,6 +372,7 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
|
stdenv.lib.platforms.illumos ++
|
||||||
stdenv.lib.platforms.darwin;
|
stdenv.lib.platforms.darwin;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -39,8 +39,6 @@ with builtins;
|
|||||||
|
|
||||||
let version = "8.2.0";
|
let version = "8.2.0";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
@ -335,10 +333,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -362,6 +363,7 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
|
stdenv.lib.platforms.illumos ++
|
||||||
stdenv.lib.platforms.darwin;
|
stdenv.lib.platforms.darwin;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -40,8 +40,6 @@ with builtins;
|
|||||||
|
|
||||||
let version = "7-20170409";
|
let version = "7-20170409";
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
inherit (stdenv) buildPlatform hostPlatform targetPlatform;
|
||||||
|
|
||||||
patches =
|
patches =
|
||||||
@ -306,10 +304,13 @@ stdenv.mkDerivation ({
|
|||||||
"-Wl,-rpath-link,${libcCross.out}/lib"
|
"-Wl,-rpath-link,${libcCross.out}/lib"
|
||||||
]));
|
]));
|
||||||
|
|
||||||
passthru =
|
passthru = {
|
||||||
{ inherit langC langCC langObjC langObjCpp langFortran langGo version; isGNU = true; };
|
inherit langC langCC langObjC langObjCpp langFortran langGo version;
|
||||||
|
isGNU = true;
|
||||||
|
};
|
||||||
|
|
||||||
inherit enableParallelBuilding enableMultilib;
|
enableParallelBuilding = true;
|
||||||
|
inherit enableMultilib;
|
||||||
|
|
||||||
inherit (stdenv) is64bit;
|
inherit (stdenv) is64bit;
|
||||||
|
|
||||||
@ -333,6 +334,7 @@ stdenv.mkDerivation ({
|
|||||||
platforms =
|
platforms =
|
||||||
stdenv.lib.platforms.linux ++
|
stdenv.lib.platforms.linux ++
|
||||||
stdenv.lib.platforms.freebsd ++
|
stdenv.lib.platforms.freebsd ++
|
||||||
|
stdenv.lib.platforms.illumos ++
|
||||||
stdenv.lib.platforms.darwin;
|
stdenv.lib.platforms.darwin;
|
||||||
|
|
||||||
broken = true;
|
broken = true;
|
||||||
|
Loading…
Reference in New Issue
Block a user