Message ID | 039023c844a5fa57c050bab868677dabd08b1bb0.1626535972.git.public@yoctocell.xyz |
---|---|
State | Accepted |
Headers | show |
Series | [bug#49606] gnu: Add ghc-8.10. | expand |
Context | Check | Description |
---|---|---|
cbaines/applying patch | fail | View Laminar job |
cbaines/issue | success | View issue |
Hi! Xinglu Chen <public@yoctocell.xyz> writes: > * gnu/packages/haskell.scm (ghc-8.10): New variable. > --- > Two tests are failing, I am not sure why, but I have already spent too much > time on this. > [...] > + (add-after 'skip-more-tests 'skip-even-more-tests > + (lambda _ > + ;; Not sure why these tests fail > + (substitute* '("testsuite/tests/driver/T8602/T8602.T" This test looks like it's failing because it has a "#! /bin/sh" shebang in 'T8602.script'. > + "testsuite/tests/driver/T16521/all.T") This test looks like it's the only one which uses '-include-cpp-deps', and it looks like it's the only test which includes a file in the libraries directory. Perhaps a search path issue? Hope that helps, Sarah
On Sat, Jul 17 2021, Sarah Morgensen via Guix-patches via wrote: > Hi! > > Xinglu Chen <public@yoctocell.xyz> writes: > >> * gnu/packages/haskell.scm (ghc-8.10): New variable. >> --- >> Two tests are failing, I am not sure why, but I have already spent too much >> time on this. >> [...] >> + (add-after 'skip-more-tests 'skip-even-more-tests >> + (lambda _ >> + ;; Not sure why these tests fail >> + (substitute* '("testsuite/tests/driver/T8602/T8602.T" > > This test looks like it's failing because it has a "#! /bin/sh" shebang > in 'T8602.script'. Ah, good catch! >> + "testsuite/tests/driver/T16521/all.T") > > This test looks like it's the only one which uses '-include-cpp-deps', > and it looks like it's the only test which includes a file in the > libraries directory. Perhaps a search path issue? I am not familiar with CPP stuff, but I will see what I can do about it. Thank you for the pointers! I will try to find some time to work on this during the weekend.
diff --git a/gnu/packages/haskell.scm b/gnu/packages/haskell.scm index 09732fc594..4e31867bfd 100644 --- a/gnu/packages/haskell.scm +++ b/gnu/packages/haskell.scm @@ -657,6 +657,58 @@ interactive environment for the functional language Haskell.") (file-pattern ".*\\.conf\\.d$") (file-type 'directory)))))) +(define-public ghc-8.10 + (package + (inherit ghc-8.8) + (name "ghc") + (version "8.10.5") + (source + (origin + (method url-fetch) + (uri (string-append "https://www.haskell.org/ghc/dist/" + version "/ghc-" version "-src.tar.xz")) + (sha256 + (base32 "0vq7wch0wfvy2b5dbi308lq5225vf691n95m19c9igagdvql22gi")))) + (native-inputs + `(("ghc-bootstrap" ,ghc-8.8) + ("ghc-testsuite" + ,(origin + (method url-fetch) + (uri (string-append + "https://www.haskell.org/ghc/dist/" + version "/ghc-" version "-testsuite.tar.xz")) + (patches (search-patches "ghc-testsuite-dlopen-pie.patch")) + (sha256 + (base32 + "0vcq774rfb6q8vsnh7p5clxp2qaz8ip6d2bm2ghbq53n8jl296d6")))) + ("git" ,git-minimal) ; invoked during tests + ,@(filter (match-lambda + (("ghc-bootstrap" . _) #f) + (("ghc-testsuite" . _) #f) + (_ #t)) + (package-native-inputs ghc-8.8)))) + (arguments + (substitute-keyword-arguments (package-arguments ghc-8.8) + ((#:phases phases '%standard-phases) + `(modify-phases ,phases + (add-after 'unpack 'fix-cc-name + (lambda _ + (substitute* "utils/hsc2hs/Common.hs" + (("\"cc\"") "\"gcc\"")))) + (add-after 'skip-more-tests 'skip-even-more-tests + (lambda _ + ;; Not sure why these tests fail + (substitute* '("testsuite/tests/driver/T8602/T8602.T" + "testsuite/tests/driver/T16521/all.T") + (("^.*" all) + (string-append "# guix skipped: " all))))))))) + (native-search-paths (list (search-path-specification + (variable "GHC_PACKAGE_PATH") + (files (list + (string-append "lib/ghc-" version))) + (file-pattern ".*\\.conf\\.d$") + (file-type 'directory)))))) + (define-public ghc-8 ghc-8.6) (define-public ghc ghc-8)