diff options
author | Adam Joseph <adam@westernsemico.com> | 2023-03-07 02:04:27 -0800 |
---|---|---|
committer | Adam Joseph <adam@westernsemico.com> | 2023-03-07 02:04:27 -0800 |
commit | 8a05f77b5d4d8422624828f9744daee1b9b213d4 (patch) | |
tree | e046b4f1f9b660b89a1e0d03086dc3c540fa5aec /pkgs/development/compilers/gcc/11/default.nix | |
parent | c3547bc6ebce55124a5c9a53c81686efbdd7a957 (diff) | |
download | nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar.gz nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar.bz2 nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar.lz nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar.xz nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.tar.zst nixpkgs-8a05f77b5d4d8422624828f9744daee1b9b213d4.zip |
https://github.com/NixOS/nixpkgs/pull/217995#pullrequestreview-1318620540
Diffstat (limited to 'pkgs/development/compilers/gcc/11/default.nix')
-rw-r--r-- | pkgs/development/compilers/gcc/11/default.nix | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/pkgs/development/compilers/gcc/11/default.nix b/pkgs/development/compilers/gcc/11/default.nix index 2f6e986f3eb..b2330abd4b7 100644 --- a/pkgs/development/compilers/gcc/11/default.nix +++ b/pkgs/development/compilers/gcc/11/default.nix @@ -250,8 +250,10 @@ stdenv.mkDerivation ({ targetConfig = if targetPlatform != hostPlatform then targetPlatform.config else null; buildFlags = - lib.optionalString (profiledCompiler) "profiled" + - lib.optionalString (targetPlatform == hostPlatform && hostPlatform == buildPlatform && !disableBootstrap) "bootstrap"; + let target = + lib.optionalString (profiledCompiler) "profiled" + + lib.optionalString (targetPlatform == hostPlatform && hostPlatform == buildPlatform && !disableBootstrap) "bootstrap"; + in lib.optional (target != "") target; inherit (callFile ../common/strip-attributes.nix { }) stripDebugList |