[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
328/328: gnu: ghc-haddock: Update to 2.22.0.
From: |
guix-commits |
Subject: |
328/328: gnu: ghc-haddock: Update to 2.22.0. |
Date: |
Sat, 16 Nov 2019 19:33:36 -0500 (EST) |
samplet pushed a commit to branch wip-haskell-updates
in repository guix.
commit 51a34ae59139fb707dba215d5aed049a5aa6b34e
Author: Timothy Sample <address@hidden>
Date: Fri Nov 15 20:00:27 2019 -0500
gnu: ghc-haddock: Update to 2.22.0.
* gnu/packages/haskell-xyz.scm (ghc-haddock): Update to 2.22.0.
[arguments]: Replace the 'remove-haddock-test-test-suites' phase with a
'remove-hoogle-test' phase, which only disables the Hoogle test; add a
new phase that puts the newly built 'haddock' binary in the 'PATH'
variable for testing.
[native-inputs]: Add 'ghc-haddock-test'.
(ghc-haddock-test): New variable.
---
gnu/packages/haskell-xyz.scm | 61 ++++++++++++++++++++++++++++++++++----------
1 file changed, 48 insertions(+), 13 deletions(-)
diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm
index da4e746..7bf97ae 100644
--- a/gnu/packages/haskell-xyz.scm
+++ b/gnu/packages/haskell-xyz.scm
@@ -4689,7 +4689,7 @@ Tor project}.")
(define-public ghc-haddock
(package
(name "ghc-haddock")
- (version "2.19.0.1")
+ (version "2.22.0")
(source
(origin
(method url-fetch)
@@ -4699,16 +4699,15 @@ Tor project}.")
".tar.gz"))
(sha256
(base32
- "1g1j9j0hf2yhyyh0gwz6bzbvfvliqz9x8a8hnkmwghm7w3xa6sb7"))))
+ "1k42z2zh550rl93c8pa9cg2xsanp6wvb031xvan6cmngnplmdib6"))))
(build-system haskell-build-system)
(arguments
`(#:phases
(modify-phases %standard-phases
- ;; There are four test suites that require the ghc-haddock-test
- ;; package, which no longer builds with GHC 8.4.3. This phase
- ;; removes these four test suites from the Cabal file, so that we
- ;; do not need ghc-haddock-test as an input.
- (add-before 'configure 'remove-haddock-test-test-suites
+ ;; The release tarball for 2.22.0 is missing the test data for
+ ;; the Hoogle test, causing it to fail. This is fixed in the
+ ;; next release, but for now we disable it.
+ (add-before 'configure 'remove-hoogle-test
(lambda _
(use-modules (ice-9 rdelim))
(with-atomic-file-replacement "haddock.cabal"
@@ -4719,17 +4718,20 @@ Tor project}.")
((string-every char-set:whitespace line)
(unless deleting? (display line out))
(loop (read-line in 'concat) #f))
- ((member line '("test-suite html-test\n"
- "test-suite hypsrc-test\n"
- "test-suite latex-test\n"
- "test-suite hoogle-test\n"))
+ ((string=? line "test-suite hoogle-test\n")
(loop (read-line in 'concat) #t))
(else
(unless deleting? (display line out))
- (loop (read-line in 'concat) deleting?)))))))))))
+ (loop (read-line in 'concat) deleting?))))))))
+ (add-before 'check 'add-haddock-to-path
+ (lambda _
+ (setenv "PATH" (string-append (getcwd) "/dist/build/haddock"
+ ":" (getenv "PATH")))
+ #t)))))
(inputs `(("ghc-haddock-api" ,ghc-haddock-api)))
(native-inputs
- `(("ghc-hspec" ,ghc-hspec)))
+ `(("ghc-haddock-test" ,ghc-haddock-test)
+ ("ghc-hspec" ,ghc-hspec)))
(home-page "https://www.haskell.org/haddock/")
(synopsis
"Documentation-generation tool for Haskell libraries")
@@ -4819,6 +4821,39 @@ project if you can't release often. For interacting
with Haddock itself, see
the ‘haddock’ package.")
(license license:bsd-3)))
+;; This package is needed for testing 'ghc-haddock'. It is no longer
+;; published to Hackage, but it is maintained in the Haddock Git
+;; repository.
+(define ghc-haddock-test
+ (package
+ (name "ghc-haddock-test")
+ (version "2.22.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/haskell/haddock.git")
+ (commit (string-append "haddock-" version "-release"))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1ywxmqqan10gs0ppybdmdgsmvkzkpw7yirj2rw4qylg3x49a9zca"))))
+ (build-system haskell-build-system)
+ (arguments
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'unpack 'change-directory
+ (lambda _
+ (chdir "haddock-test"))))))
+ (inputs
+ `(("ghc-syb" ,ghc-syb)
+ ("ghc-xml" ,ghc-xml)))
+ (home-page "http://www.haskell.org/haddock/")
+ (synopsis "Test utilities for Haddock")
+ (description "This package provides test utilities for Haddock.")
+ (license license:bsd-3)
+ (properties '((hidden? #t)))))
+
(define-public ghc-half
(package
(name "ghc-half")
- 301/328: gnu: agda: Update to 2.6.0.1., (continued)
- 301/328: gnu: agda: Update to 2.6.0.1., guix-commits, 2019/11/16
- 313/328: gnu: Add ghc-size-based., guix-commits, 2019/11/16
- 321/328: gnu: Add ghc-active., guix-commits, 2019/11/16
- 318/328: gnu: Add ghc-diagrams-core., guix-commits, 2019/11/16
- 323/328: gnu: Add ghc-diagrams-lib., guix-commits, 2019/11/16
- 322/328: gnu: Add ghc-diagrams-solve., guix-commits, 2019/11/16
- 294/328: gnu: ghc-options: Fix Cabal dependency constraints., guix-commits, 2019/11/16
- 300/328: gnu: ghc-atomic-primops: Update to 0.8.3., guix-commits, 2019/11/16
- 298/328: gnu: ghc-equivalence: Update to 0.3.5., guix-commits, 2019/11/16
- 312/328: gnu: Add ghc-dictionary-sharing., guix-commits, 2019/11/16
- 328/328: gnu: ghc-haddock: Update to 2.22.0.,
guix-commits <=
- 230/328: gnu: ghc-conduit-extra: Update to 1.3.4., guix-commits, 2019/11/16
- 234/328: gnu: ghc-bzlib-conduit: Update to 0.3.0.2., guix-commits, 2019/11/16
- 238/328: gnu: Add ghc-infer-license., guix-commits, 2019/11/16
- 280/328: gnu: Add ghc-microlens-aeson., guix-commits, 2019/11/16
- 279/328: gnu: Add ghc-hsyaml., guix-commits, 2019/11/16
- 297/328: gnu: ghc-geniplate-mirror: Update Cabal file to r2., guix-commits, 2019/11/16
- 227/328: gnu: ghc-foldl: Update to 1.4.5., guix-commits, 2019/11/16
- 232/328: gnu: Add ghc-libyaml., guix-commits, 2019/11/16
- 241/328: gnu: hlint: Update to 2.1.26., guix-commits, 2019/11/16
- 239/328: gnu: ghc-hpack: Update to 0.31.2., guix-commits, 2019/11/16