mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-04-16 03:08:11 +00:00
pkgsStatic.python3: fix build
GCC does not come with a `libgcc_eh.a` for the target platform if
it was built without `--enable-shared`. That flag was removed with
c6dd11ca39
, meaning we should no longer
attempt to link against that lib.
This commit is contained in:
parent
41cc1d5d95
commit
1e447d7898
@ -289,7 +289,7 @@ in with passthru; stdenv.mkDerivation {
|
||||
CPPFLAGS = concatStringsSep " " (map (p: "-I${getDev p}/include") buildInputs);
|
||||
LDFLAGS = concatStringsSep " " (map (p: "-L${getLib p}/lib") buildInputs);
|
||||
LIBS = "${optionalString (!stdenv.isDarwin) "-lcrypt"}";
|
||||
NIX_LDFLAGS = lib.optionalString stdenv.cc.isGNU ({
|
||||
NIX_LDFLAGS = lib.optionalString (stdenv.cc.isGNU && !stdenv.hostPlatform.isStatic) ({
|
||||
"glibc" = "-lgcc_s";
|
||||
"musl" = "-lgcc_eh";
|
||||
}."${stdenv.hostPlatform.libc}" or "");
|
||||
|
Loading…
Reference in New Issue
Block a user