From a9ac31c299743960d4670e0e28d07777a6e87230 Mon Sep 17 00:00:00 2001 From: Divam Date: Wed, 5 Aug 2020 14:51:06 +0900 Subject: [PATCH] Set the STRIP_CMD to ':' for dontStrip (as mentioned in mk/build.mk.sample) --- pkgs/development/compilers/ghc/8.10.1.nix | 8 ++++++-- pkgs/development/compilers/ghc/8.8.2.nix | 8 ++++++-- pkgs/development/compilers/ghc/8.8.3.nix | 8 ++++++-- pkgs/development/compilers/ghc/8.8.4.nix | 8 ++++++-- pkgs/development/compilers/ghc/head.nix | 8 ++++++-- 5 files changed, 30 insertions(+), 10 deletions(-) diff --git a/pkgs/development/compilers/ghc/8.10.1.nix b/pkgs/development/compilers/ghc/8.10.1.nix index 9da80fa5c207..77fac7e1a4e8 100644 --- a/pkgs/development/compilers/ghc/8.10.1.nix +++ b/pkgs/development/compilers/ghc/8.10.1.nix @@ -55,7 +55,7 @@ let (targetPlatform != hostPlatform) "${targetPlatform.config}-"; - buildMK = '' + buildMK = dontStrip: '' BuildFlavour = ${ghcFlavour} ifneq \"\$(BuildFlavour)\" \"\" include mk/flavours/\$(BuildFlavour).mk @@ -68,6 +68,8 @@ let HADDOCK_DOCS = NO BUILD_SPHINX_HTML = NO BUILD_SPHINX_PDF = NO + '' + stdenv.lib.optionalString dontStrip '' + STRIP_CMD = : '' + stdenv.lib.optionalString (!enableProfiliedLibs) '' GhcLibWays = "v dyn" '' + stdenv.lib.optionalString enableRelocatedStaticLibs '' @@ -127,7 +129,7 @@ stdenv.mkDerivation (rec { export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf" export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip" - echo -n "${buildMK}" > mk/build.mk + echo -n "${buildMK dontStrip}" > mk/build.mk sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure '' + stdenv.lib.optionalString (!stdenv.isDarwin) '' export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}" @@ -211,6 +213,8 @@ stdenv.mkDerivation (rec { hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie"; + dontStrip = false; + postInstall = '' # 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.8.2.nix b/pkgs/development/compilers/ghc/8.8.2.nix index 305226b34079..7470290a6bd7 100644 --- a/pkgs/development/compilers/ghc/8.8.2.nix +++ b/pkgs/development/compilers/ghc/8.8.2.nix @@ -52,7 +52,7 @@ let (targetPlatform != hostPlatform) "${targetPlatform.config}-"; - buildMK = '' + buildMK = dontStrip: '' BuildFlavour = ${ghcFlavour} ifneq \"\$(BuildFlavour)\" \"\" include mk/flavours/\$(BuildFlavour).mk @@ -65,6 +65,8 @@ let HADDOCK_DOCS = NO BUILD_SPHINX_HTML = NO BUILD_SPHINX_PDF = NO + '' + stdenv.lib.optionalString dontStrip '' + STRIP_CMD = : '' + stdenv.lib.optionalString enableRelocatedStaticLibs '' GhcLibHcOpts += -fPIC GhcRtsHcOpts += -fPIC @@ -122,7 +124,7 @@ stdenv.mkDerivation (rec { export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf" export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip" - echo -n "${buildMK}" > mk/build.mk + echo -n "${buildMK dontStrip}" > mk/build.mk sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure '' + stdenv.lib.optionalString (!stdenv.isDarwin) '' export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}" @@ -206,6 +208,8 @@ stdenv.mkDerivation (rec { hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie"; + dontStrip = false; + postInstall = '' # 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.8.3.nix b/pkgs/development/compilers/ghc/8.8.3.nix index c22327efce36..fcfaba330bef 100644 --- a/pkgs/development/compilers/ghc/8.8.3.nix +++ b/pkgs/development/compilers/ghc/8.8.3.nix @@ -55,7 +55,7 @@ let (targetPlatform != hostPlatform) "${targetPlatform.config}-"; - buildMK = '' + buildMK = dontStrip: '' BuildFlavour = ${ghcFlavour} ifneq \"\$(BuildFlavour)\" \"\" include mk/flavours/\$(BuildFlavour).mk @@ -68,6 +68,8 @@ let HADDOCK_DOCS = NO BUILD_SPHINX_HTML = NO BUILD_SPHINX_PDF = NO + '' + stdenv.lib.optionalString dontStrip '' + STRIP_CMD = : '' + stdenv.lib.optionalString (!enableProfiliedLibs) '' GhcLibWays = "v dyn" '' + stdenv.lib.optionalString enableRelocatedStaticLibs '' @@ -127,7 +129,7 @@ stdenv.mkDerivation (rec { export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf" export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip" - echo -n "${buildMK}" > mk/build.mk + echo -n "${buildMK dontStrip}" > mk/build.mk sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure '' + stdenv.lib.optionalString (!stdenv.isDarwin) '' export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}" @@ -211,6 +213,8 @@ stdenv.mkDerivation (rec { hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie"; + dontStrip = false; + postInstall = '' # 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.8.4.nix b/pkgs/development/compilers/ghc/8.8.4.nix index 515ff2d646b8..71c4cab3204e 100644 --- a/pkgs/development/compilers/ghc/8.8.4.nix +++ b/pkgs/development/compilers/ghc/8.8.4.nix @@ -55,7 +55,7 @@ let (targetPlatform != hostPlatform) "${targetPlatform.config}-"; - buildMK = '' + buildMK = dontStrip: '' BuildFlavour = ${ghcFlavour} ifneq \"\$(BuildFlavour)\" \"\" include mk/flavours/\$(BuildFlavour).mk @@ -68,6 +68,8 @@ let HADDOCK_DOCS = NO BUILD_SPHINX_HTML = NO BUILD_SPHINX_PDF = NO + '' + stdenv.lib.optionalString dontStrip '' + STRIP_CMD = : '' + stdenv.lib.optionalString (!enableProfiliedLibs) '' GhcLibWays = "v dyn" '' + stdenv.lib.optionalString enableRelocatedStaticLibs '' @@ -127,7 +129,7 @@ stdenv.mkDerivation (rec { export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf" export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip" - echo -n "${buildMK}" > mk/build.mk + echo -n "${buildMK dontStrip}" > mk/build.mk sed -i -e 's|-isysroot /Developer/SDKs/MacOSX10.5.sdk||' configure '' + stdenv.lib.optionalString (!stdenv.isDarwin) '' export NIX_LDFLAGS+=" -rpath $out/lib/ghc-${version}" @@ -211,6 +213,8 @@ stdenv.mkDerivation (rec { hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie"; + dontStrip = false; + postInstall = '' # 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 a15ef7f7dbf8..0fca12d087cd 100644 --- a/pkgs/development/compilers/ghc/head.nix +++ b/pkgs/development/compilers/ghc/head.nix @@ -58,7 +58,7 @@ let (targetPlatform != hostPlatform) "${targetPlatform.config}-"; - buildMK = '' + buildMK = dontStrip: '' BuildFlavour = ${ghcFlavour} ifneq \"\$(BuildFlavour)\" \"\" include mk/flavours/\$(BuildFlavour).mk @@ -71,6 +71,8 @@ let HADDOCK_DOCS = NO BUILD_SPHINX_HTML = NO BUILD_SPHINX_PDF = NO + '' + stdenv.lib.optionalString dontStrip '' + STRIP_CMD = : '' + stdenv.lib.optionalString enableRelocatedStaticLibs '' GhcLibHcOpts += -fPIC GhcRtsHcOpts += -fPIC @@ -132,7 +134,7 @@ stdenv.mkDerivation (rec { export READELF="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}readelf" export STRIP="${targetCC.bintools.bintools}/bin/${targetCC.bintools.targetPrefix}strip" - echo -n "${buildMK}" > mk/build.mk + echo -n "${buildMK dontStrip}" > mk/build.mk echo ${version} > VERSION echo ${src.rev} > GIT_COMMIT_ID ./boot @@ -222,6 +224,8 @@ stdenv.mkDerivation (rec { hardeningDisable = [ "format" ] ++ stdenv.lib.optional stdenv.targetPlatform.isMusl "pie"; + dontStrip = false; + postInstall = '' # Install the bash completion file. install -D -m 444 utils/completion/ghc.bash $out/share/bash-completion/completions/${targetPrefix}ghc