summaryrefslogtreecommitdiff
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
parent54052a54c1188002b2040b8b24f8605d1c0fac1f (diff)
downloadguix-patches-d8e85b20325073d90cfaf3060889d59d91362deb.tar
guix-patches-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.
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/haskell.scm31
-rw-r--r--gnu/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch27
3 files changed, 36 insertions, 23 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 6450da1de0..269af5fe12 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -575,6 +575,7 @@ dist_patch_DATA = \
%D%/packages/patches/gd-fix-truecolor-format-correction.patch \
%D%/packages/patches/gegl-CVE-2012-4433.patch \
%D%/packages/patches/geoclue-config.patch \
+ %D%/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch \
%D%/packages/patches/ghostscript-CVE-2013-5653.patch \
%D%/packages/patches/ghostscript-CVE-2015-3228.patch \
%D%/packages/patches/ghostscript-CVE-2016-7976.patch \
diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm
index 56b0090ee0..37e35c45fd 100644
--- a/gnu/packages/haskell.scm
+++ b/gnu/packages/haskell.scm
@@ -26,6 +26,7 @@
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (gnu packages haskell)
+ #:use-module (gnu packages)
#:use-module (gnu packages bootstrap)
#:use-module (gnu packages compression)
#:use-module (gnu packages elf)
@@ -267,14 +268,17 @@ interactive environment for the functional language Haskell.")
(define-public ghc-8
(package
(name "ghc")
- (version "8.0.1")
+ (version "8.0.2")
(source
(origin
(method url-fetch)
(uri (string-append "https://www.haskell.org/ghc/dist/"
version "/" name "-" version "-src.tar.xz"))
(sha256
- (base32 "1lniqy29djhjkddnailpaqhlqh4ld2mqvb1fxgxw1qqjhz6j1ywh"))))
+ (base32 "1c8qc4fhkycynk4g1f9hvk53dj6a1vvqi6bklqznns6hw59m8qhi"))
+ (patches
+ (search-patches
+ "ghc-dont-pass-linker-flags-via-response-files.patch"))))
(build-system gnu-build-system)
(supported-systems '("i686-linux" "x86_64-linux"))
(outputs '("out" "doc"))
@@ -290,7 +294,7 @@ interactive environment for the functional language Haskell.")
"https://www.haskell.org/ghc/dist/"
version "/" name "-" version "-testsuite.tar.xz"))
(sha256
- (base32 "0lc1vjivkxn01aw3jg2gd7fmqb5pj7a5j987c7pn5r7caqv1cmxw"))))))
+ (base32 "1wjc3x68l305bl1h1ijd3yhqp2vqj83lkp3kqbr94qmmkqlms8sj"))))))
(native-inputs
`(("perl" ,perl)
("python" ,python-2) ; for tests
@@ -312,13 +316,6 @@ interactive environment for the functional language Haskell.")
;; then complains that they don't match.
#:build #f
- #:modules ((guix build gnu-build-system)
- (guix build utils)
- (guix build rpath)
- (srfi srfi-26)
- (srfi srfi-1))
- #:imported-modules (,@%gnu-build-system-modules
- (guix build rpath))
#:configure-flags
(list
(string-append "--with-gmp-libraries="
@@ -366,19 +363,7 @@ interactive environment for the functional language Haskell.")
"testsuite/tests/programs/life_space_leak/life.test")
(("/bin/sh") (which "sh"))
(("/bin/rm") "rm"))
- #t))
- ;; the testsuite can't find shared libraries.
- (add-before 'check 'configure-testsuite
- (lambda* (#:key inputs #:allow-other-keys)
- (let* ((gmp (assoc-ref inputs "gmp"))
- (gmp-lib (string-append gmp "/lib"))
- (ffi (assoc-ref inputs "libffi"))
- (ffi-lib (string-append ffi "/lib"))
- (ncurses (assoc-ref inputs "ncurses"))
- (ncurses-lib (string-append ncurses "/lib")))
- (setenv "LD_LIBRARY_PATH"
- (string-append gmp-lib ":" ffi-lib ":" ncurses-lib))
- #t))))))
+ #t)))))
(native-search-paths (list (search-path-specification
(variable "GHC_PACKAGE_PATH")
(files (list
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