summary refs log tree commit diff
path: root/gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch
diff options
context:
space:
mode:
authorFederico Beffa <beffa@fbengineering.ch>2017-01-25 18:21:43 +0100
committerFederico Beffa <beffa@fbengineering.ch>2017-01-30 14:39:35 +0100
commitd8e85b20325073d90cfaf3060889d59d91362deb (patch)
treea0100ccbc6b4f0e6cfe7e4ddcf2c769aa6ca31bb /gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch
parent54052a54c1188002b2040b8b24f8605d1c0fac1f (diff)
downloadguix-d8e85b20325073d90cfaf3060889d59d91362deb.tar.gz
gnu: ghc-8: Update to 8.0.2.
* gnu/packages/haskell.scm (ghc-8): Update to 8.0.2.
  [arguments]: Remove #:modules, #:imported-modules and phase
  configure-testsuite.
* gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch:
  New file.
* gnu/local.mk (dist_patch_DATA): Add it.
Diffstat (limited to 'gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch')
-rw-r--r--gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch b/gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch
new file mode 100644
index 0000000000..40aae7a9d7
--- /dev/null
+++ b/gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch
@@ -0,0 +1,27 @@
+Don’t add linker flags via ‘response files’ since ld-wrapper
+doesn’t handle them.
+See https://github.com/NixOS/nixpkgs/commit/a421e7bd4a28c69bded8b17888325e31554f61a1
+https://gcc.gnu.org/ml/gcc/2016-10/msg00151.html
+
+diff --git a/compiler/main/SysTools.hs.orig b/compiler/main/SysTools.hs
+index 1ab5b13..99270fc 100644
+--- a/compiler/main/SysTools.hs.orig
++++ b/compiler/main/SysTools.hs
+@@ -424,7 +424,7 @@ runCc dflags args =   do
+       args1 = map Option (getOpts dflags opt_c)
+       args2 = args0 ++ args1 ++ args
+   mb_env <- getGccEnv args2
+-  runSomethingResponseFile dflags cc_filter "C Compiler" p args2 mb_env
++  runSomethingFiltered dflags cc_filter "C Compiler" p args2 mb_env
+  where
+   -- discard some harmless warnings from gcc that we can't turn off
+   cc_filter = unlines . doFilter . lines
+@@ -945,7 +945,7 @@ runLink dflags args = do
+       args1     = map Option (getOpts dflags opt_l)
+       args2     = args0 ++ linkargs ++ args1 ++ args
+   mb_env <- getGccEnv args2
+-  runSomethingResponseFile dflags ld_filter "Linker" p args2 mb_env
++  runSomethingFiltered dflags ld_filter "Linker" p args2 mb_env
+   where
+     ld_filter = case (platformOS (targetPlatform dflags)) of
+                   OSSolaris2 -> sunos_ld_filter