diff --git a/pkgs/development/compilers/gcc/snapshot/default.nix b/pkgs/development/compilers/gcc/snapshot/default.nix index 38df9de08c2..48840ffa7c2 100644 --- a/pkgs/development/compilers/gcc/snapshot/default.nix +++ b/pkgs/development/compilers/gcc/snapshot/default.nix @@ -105,7 +105,7 @@ let version = "7-20170409"; gccFpu = platform.gcc.fpu or null; gccFloat = platform.gcc.float or null; gccMode = platform.gcc.mode or null; - in + in optional (gccArch != null) "--with-arch=${gccArch}" ++ optional (gccCpu != null) "--with-cpu=${gccCpu}" ++ optional (gccAbi != null) "--with-abi=${gccAbi}" ++ @@ -412,7 +412,7 @@ stdenv.mkDerivation ({ CC_FOR_TARGET = "${targetPlatform.config}-gcc"; NM_FOR_TARGET = "${targetPlatform.config}-nm"; CXX_FOR_TARGET = "${targetPlatform.config}-g++"; - # If we are making a cross compiler, cross != null + # If we are making a cross compiler, targetPlatform != hostPlatform NIX_CC_CROSS = optionalString (targetPlatform == hostPlatform) builtins.toString stdenv.cc; dontStrip = true; configureFlags =