diff options
author | Moritz Angermann <moritz.angermann@gmail.com> | 2018-03-05 21:34:31 +0800 |
---|---|---|
committer | John Ericson <John.Ericson@Obsidian.Systems> | 2018-05-23 10:41:15 -0400 |
commit | 10b76a4caba015a5252cc88172d3b7d23b14d8f6 (patch) | |
tree | e6ca4b62d89154953d859d7eda22f05246250240 /pkgs/development/compilers/ghc | |
parent | 1978115c3b2dfcb33f78673677a0ef3ffa6a0565 (diff) | |
download | nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar.gz nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar.bz2 nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar.lz nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar.xz nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.tar.zst nixlib-10b76a4caba015a5252cc88172d3b7d23b14d8f6.zip |
ghc: paxmark all unwraped executables across the board
Shell glob works even as the exact set of executable (filenames) varries beween configuations. Need to skip non ELFs (e.g. shell scripts), however.
Diffstat (limited to 'pkgs/development/compilers/ghc')
-rw-r--r-- | pkgs/development/compilers/ghc/8.0.2.nix | 7 | ||||
-rw-r--r-- | pkgs/development/compilers/ghc/8.2.2.nix | 7 | ||||
-rw-r--r-- | pkgs/development/compilers/ghc/8.4.2.nix | 7 | ||||
-rw-r--r-- | pkgs/development/compilers/ghc/head.nix | 7 |
4 files changed, 16 insertions, 12 deletions
diff --git a/pkgs/development/compilers/ghc/8.0.2.nix b/pkgs/development/compilers/ghc/8.0.2.nix index 2e627473fc21..2957846cd59d 100644 --- a/pkgs/development/compilers/ghc/8.0.2.nix +++ b/pkgs/development/compilers/ghc/8.0.2.nix @@ -164,10 +164,11 @@ stdenv.mkDerivation rec { # that in turn causes GHCi to abort stripDebugFlags = [ "-S" ] ++ stdenv.lib.optional (!targetPlatform.isDarwin) "--keep-file-symbols"; - # zsh and other shells are smart about `{ghc}` but bash isn't, and doesn't - # treat that as a unary `{x,y,z,..}` repetition. postInstall = '' - paxmark m $out/lib/${name}/bin/${if targetPlatform != hostPlatform then "ghc" else "{ghc,haddock}"} + for bin in "$out"/lib/${name}/bin/*; do + isELF "$bin" || continue + paxmark m "$bin" + done # Install the bash completion file. install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc diff --git a/pkgs/development/compilers/ghc/8.2.2.nix b/pkgs/development/compilers/ghc/8.2.2.nix index beaf761bd426..c21fd3353c74 100644 --- a/pkgs/development/compilers/ghc/8.2.2.nix +++ b/pkgs/development/compilers/ghc/8.2.2.nix @@ -179,10 +179,11 @@ stdenv.mkDerivation rec { checkTarget = "test"; - # zsh and other shells are smart about `{ghc}` but bash isn't, and doesn't - # treat that as a unary `{x,y,z,..}` repetition. postInstall = '' - paxmark m $out/lib/${name}/bin/${if targetPlatform != hostPlatform then "ghc" else "{ghc,haddock}"} + for bin in "$out"/lib/${name}/bin/*; do + isELF "$bin" || continue + paxmark m "$bin" + done # Install the bash completion file. install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc diff --git a/pkgs/development/compilers/ghc/8.4.2.nix b/pkgs/development/compilers/ghc/8.4.2.nix index 449edef662d9..7cdf746c5820 100644 --- a/pkgs/development/compilers/ghc/8.4.2.nix +++ b/pkgs/development/compilers/ghc/8.4.2.nix @@ -171,10 +171,11 @@ stdenv.mkDerivation rec { checkTarget = "test"; - # zsh and other shells are smart about `{ghc}` but bash isn't, and doesn't - # treat that as a unary `{x,y,z,..}` repetition. postInstall = '' - paxmark m $out/lib/${name}/bin/${if targetPlatform != hostPlatform then "ghc" else "{ghc,haddock}"} + for bin in "$out"/lib/${name}/bin/*; do + isELF "$bin" || continue + paxmark m "$bin" + done # Install the bash completion file. install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc diff --git a/pkgs/development/compilers/ghc/head.nix b/pkgs/development/compilers/ghc/head.nix index f5a7be5156d7..1fe6271033f4 100644 --- a/pkgs/development/compilers/ghc/head.nix +++ b/pkgs/development/compilers/ghc/head.nix @@ -169,10 +169,11 @@ stdenv.mkDerivation rec { checkTarget = "test"; - # zsh and other shells are smart about `{ghc}` but bash isn't, and doesn't - # treat that as a unary `{x,y,z,..}` repetition. postInstall = '' - paxmark m $out/lib/${name}/bin/${if targetPlatform != hostPlatform then "ghc" else "{ghc,haddock}"} + for bin in "$out"/lib/${name}/bin/*; do + isELF "$bin" || continue + paxmark m "$bin" + done # Install the bash completion file. install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc |