Skip to content

Commit

Permalink
Merge pull request #187590 from trofi/libgccjit-lib-stripping-fix
Browse files Browse the repository at this point in the history
libgccjit: don't try to enter into non-existent $lib output
  • Loading branch information
trofi authored Aug 20, 2022
2 parents 54506fb + 1f7186a commit 26c03f3
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 11 deletions.
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/10/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/11/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/12/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/4.8/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/4.9/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/6/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/7/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/8/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
2 changes: 1 addition & 1 deletion pkgs/development/compilers/gcc/9/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ stdenv.mkDerivation ({
(if profiledCompiler then "profiledbootstrap" else "bootstrap");

inherit
(import ../common/strip-attributes.nix { inherit stdenv; })
(import ../common/strip-attributes.nix { inherit lib stdenv langJit; })
stripDebugList
stripDebugListTarget
preFixup;
Expand Down
6 changes: 4 additions & 2 deletions pkgs/development/compilers/gcc/common/strip-attributes.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{ stdenv }:
{ lib, stdenv, langJit }:

{
# Note [Cross-compiler stripping]
Expand Down Expand Up @@ -48,7 +48,8 @@
lib{,32,64}/gcc/${stdenv.targetPlatform.config}/*/*.{a,o,so*}
)
popd
'' + lib.optionalString (!langJit) ''
${/*keep indentation*/ ""}
pushd $lib
local -ar libHostFiles=(
lib{,32,64}/*.{a,o,so*}
Expand All @@ -58,6 +59,7 @@
)
popd
'' + ''
eval "$oldOpts"
stripDebugList="$stripDebugList ''${outHostFiles[*]} ''${libHostFiles[*]}"
Expand Down

0 comments on commit 26c03f3

Please sign in to comment.