diff options
author | Matthew Bauer <mjbauer95@gmail.com> | 2021-01-21 19:31:26 -0600 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-21 19:31:26 -0600 |
commit | afc2edc3ee4473b3857cc76e6eb4517086641326 (patch) | |
tree | ee6234adcd637bc29ad012bce388c1041a1071f5 | |
parent | e48c1f8e8c74f44c6f9fa4c33685ca879d2d261e (diff) | |
parent | 4bdcddf9aac73d1ca1ace4eb26c14af18c1b0a31 (diff) | |
download | nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar.gz nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar.bz2 nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar.lz nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar.xz nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.tar.zst nixpkgs-afc2edc3ee4473b3857cc76e6eb4517086641326.zip |
Merge pull request #108060 from matthewbauer/strip-musl-gcc
gcc: allow stripping gcc libraries
-rw-r--r-- | pkgs/development/compilers/gcc/10/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/6/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/7/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/8/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/9/default.nix | 4 | ||||
-rw-r--r-- | pkgs/development/compilers/gcc/builder.sh | 6 |
6 files changed, 13 insertions, 13 deletions
diff --git a/pkgs/development/compilers/gcc/10/default.nix b/pkgs/development/compilers/gcc/10/default.nix index c31e7c426e0..ecbe7c9eb4b 100644 --- a/pkgs/development/compilers/gcc/10/default.nix +++ b/pkgs/development/compilers/gcc/10/default.nix @@ -28,8 +28,8 @@ , threadsCross ? null # for MinGW , crossStageStatic ? false , # Strip kills static libs of other archs (hence no cross) - stripped ? stdenv.hostPlatform == stdenv.buildPlatform - && stdenv.targetPlatform == stdenv.hostPlatform + stripped ? stdenv.hostPlatform.system == stdenv.buildPlatform.system + && stdenv.targetPlatform.system == stdenv.hostPlatform.system , gnused ? null , cloog # unused; just for compat with gcc4, as we override the parameter on some places , buildPackages diff --git a/pkgs/development/compilers/gcc/6/default.nix b/pkgs/development/compilers/gcc/6/default.nix index 908f7e0f699..ed97e6a0ce8 100644 --- a/pkgs/development/compilers/gcc/6/default.nix +++ b/pkgs/development/compilers/gcc/6/default.nix @@ -36,8 +36,8 @@ , threadsCross ? null # for MinGW , crossStageStatic ? false , # Strip kills static libs of other archs (hence no cross) - stripped ? stdenv.hostPlatform == stdenv.buildPlatform - && stdenv.targetPlatform == stdenv.hostPlatform + stripped ? stdenv.hostPlatform.system == stdenv.buildPlatform.system + && stdenv.targetPlatform.system == stdenv.hostPlatform.system , gnused ? null , cloog # unused; just for compat with gcc4, as we override the parameter on some places , buildPackages diff --git a/pkgs/development/compilers/gcc/7/default.nix b/pkgs/development/compilers/gcc/7/default.nix index d950d6ac35b..4bd776e6f8b 100644 --- a/pkgs/development/compilers/gcc/7/default.nix +++ b/pkgs/development/compilers/gcc/7/default.nix @@ -26,8 +26,8 @@ , threadsCross ? null # for MinGW , crossStageStatic ? false , # Strip kills static libs of other archs (hence no cross) - stripped ? stdenv.hostPlatform == stdenv.buildPlatform - && stdenv.targetPlatform == stdenv.hostPlatform + stripped ? stdenv.hostPlatform.system == stdenv.buildPlatform.system + && stdenv.targetPlatform.system == stdenv.hostPlatform.system , gnused ? null , cloog # unused; just for compat with gcc4, as we override the parameter on some places , buildPackages diff --git a/pkgs/development/compilers/gcc/8/default.nix b/pkgs/development/compilers/gcc/8/default.nix index 683a9edfe09..d9234a75530 100644 --- a/pkgs/development/compilers/gcc/8/default.nix +++ b/pkgs/development/compilers/gcc/8/default.nix @@ -26,8 +26,8 @@ , threadsCross ? null # for MinGW , crossStageStatic ? false , # Strip kills static libs of other archs (hence no cross) - stripped ? stdenv.hostPlatform == stdenv.buildPlatform - && stdenv.targetPlatform == stdenv.hostPlatform + stripped ? stdenv.hostPlatform.system == stdenv.buildPlatform.system + && stdenv.targetPlatform.system == stdenv.hostPlatform.system , gnused ? null , cloog # unused; just for compat with gcc4, as we override the parameter on some places , buildPackages diff --git a/pkgs/development/compilers/gcc/9/default.nix b/pkgs/development/compilers/gcc/9/default.nix index 7827cb98505..40af21a1fa3 100644 --- a/pkgs/development/compilers/gcc/9/default.nix +++ b/pkgs/development/compilers/gcc/9/default.nix @@ -29,8 +29,8 @@ , threadsCross ? null # for MinGW , crossStageStatic ? false , # Strip kills static libs of other archs (hence no cross) - stripped ? stdenv.hostPlatform == stdenv.buildPlatform - && stdenv.targetPlatform == stdenv.hostPlatform + stripped ? stdenv.hostPlatform.system == stdenv.buildPlatform.system + && stdenv.targetPlatform.system == stdenv.hostPlatform.system , gnused ? null , cloog # unused; just for compat with gcc4, as we override the parameter on some places , buildPackages diff --git a/pkgs/development/compilers/gcc/builder.sh b/pkgs/development/compilers/gcc/builder.sh index 7d104b96624..e6d41d7b29a 100644 --- a/pkgs/development/compilers/gcc/builder.sh +++ b/pkgs/development/compilers/gcc/builder.sh @@ -147,9 +147,9 @@ if test "$noSysDirs" = "1"; then fi fi -if test -n "${targetConfig-}"; then - # The host strip will destroy some important details of the objects - dontStrip=1 +if [ -n "${targetConfig-}" ]; then + # if stripping gcc, include target directory too + stripDebugList="${stripDebugList-lib lib32 lib64 libexec bin sbin} $targetConfig" fi eval "$oldOpts" |