gcc_multi: disable the hook moving lib64 to lib

This was preventing wine from build, and we typically don't want it
anyway in multilib builds. /cc #8706.

Changed files
+12 -7
pkgs
build-support
cc-wrapper
top-level
+3 -2
pkgs/build-support/cc-wrapper/default.nix
···
{ name ? "", stdenv, nativeTools, nativeLibc, nativePrefix ? ""
, cc ? null, libc ? null, binutils ? null, coreutils ? null, shell ? stdenv.shell
-
, zlib ? null, extraPackages ? []
, dyld ? null # TODO: should this be a setup-hook on dyld?
, isGNU ? false, isClang ? false
}:
···
substituteAll ${./add-flags} $out/nix-support/add-flags.sh
cp -p ${./utils.sh} $out/nix-support/utils.sh
-
'';
# The dynamic linker has different names on different Linux platforms.
dynamicLinker =
···
{ name ? "", stdenv, nativeTools, nativeLibc, nativePrefix ? ""
, cc ? null, libc ? null, binutils ? null, coreutils ? null, shell ? stdenv.shell
+
, zlib ? null, extraPackages ? [], extraBuildCommands ? ""
, dyld ? null # TODO: should this be a setup-hook on dyld?
, isGNU ? false, isClang ? false
}:
···
substituteAll ${./add-flags} $out/nix-support/add-flags.sh
cp -p ${./utils.sh} $out/nix-support/utils.sh
+
''
+
+ extraBuildCommands;
# The dynamic linker has different names on different Linux platforms.
dynamicLinker =
+9 -5
pkgs/top-level/all-packages.nix
···
gcc_multi =
if system == "x86_64-linux" then lowPrio (
-
wrapCCWith (import ../build-support/cc-wrapper) glibc_multi (gcc.cc.override {
-
stdenv = overrideCC stdenv (wrapCCWith (import ../build-support/cc-wrapper) glibc_multi gcc.cc);
profiledCompiler = false;
enableMultilib = true;
}))
···
win32hello = callPackage ../development/compilers/visual-c++/test { };
-
wrapCCWith = ccWrapper: libc: baseCC: ccWrapper {
nativeTools = stdenv.cc.nativeTools or false;
nativeLibc = stdenv.cc.nativeLibc or false;
nativePrefix = stdenv.cc.nativePrefix or "";
···
dyld = if stdenv.isDarwin then darwin.dyld else null;
isGNU = baseCC.isGNU or false;
isClang = baseCC.isClang or false;
-
inherit stdenv binutils coreutils zlib;
};
-
wrapCC = wrapCCWith (makeOverridable (import ../build-support/cc-wrapper)) stdenv.cc.libc;
# legacy version, used for gnat bootstrapping
wrapGCC-old = baseGCC: (makeOverridable (import ../build-support/gcc-wrapper-old)) {
nativeTools = stdenv.cc.nativeTools or false;
···
gcc_multi =
if system == "x86_64-linux" then lowPrio (
+
let
+
extraBuildCommands = ''
+
echo "dontMoveLib64=1" >> $out/nix-support/setup-hook
+
'';
+
in wrapCCWith (import ../build-support/cc-wrapper) glibc_multi extraBuildCommands (gcc.cc.override {
+
stdenv = overrideCC stdenv (wrapCCWith (import ../build-support/cc-wrapper) glibc_multi "" gcc.cc);
profiledCompiler = false;
enableMultilib = true;
}))
···
win32hello = callPackage ../development/compilers/visual-c++/test { };
+
wrapCCWith = ccWrapper: libc: extraBuildCommands: baseCC: ccWrapper {
nativeTools = stdenv.cc.nativeTools or false;
nativeLibc = stdenv.cc.nativeLibc or false;
nativePrefix = stdenv.cc.nativePrefix or "";
···
dyld = if stdenv.isDarwin then darwin.dyld else null;
isGNU = baseCC.isGNU or false;
isClang = baseCC.isClang or false;
+
inherit stdenv binutils coreutils zlib extraBuildCommands;
};
+
wrapCC = wrapCCWith (makeOverridable (import ../build-support/cc-wrapper)) stdenv.cc.libc "";
# legacy version, used for gnat bootstrapping
wrapGCC-old = baseGCC: (makeOverridable (import ../build-support/gcc-wrapper-old)) {
nativeTools = stdenv.cc.nativeTools or false;