From d9b1567a07ee26019e4ea12dda36d00dc3205ca6 Mon Sep 17 00:00:00 2001 From: Timothy Sample Date: Thu, 31 Oct 2019 13:33:38 -0400 Subject: gnu: ghc-pandoc: Update to 2.7.3. * gnu/packages/haskell-xyz.scm (ghc-pandoc): Update to 2.7.3. [source]: Add patches to fix tests. [arguments]: Remove '#:phases'. [inputs]: Remove 'ghc-deepseq-generics', 'ghc-old-locale', and 'ghc-yaml'; add 'ghc-hslua-module-system', 'ghc-hsyaml', 'ghc-ipynb', and 'ghc-unicode-transforms'. [native-inputs]: Add 'ghc-tasty-lua'. * gnu/packages/patches/ghc-pandoc-fix-html-tests.patch: New file. * gnu/packages/patches/ghc-pandoc-fix-latex-test.patch: New file. * gnu/local.mk: Add them. --- gnu/local.mk | 2 + gnu/packages/haskell-xyz.scm | 28 +++---- .../patches/ghc-pandoc-fix-html-tests.patch | 92 ++++++++++++++++++++++ .../patches/ghc-pandoc-fix-latex-test.patch | 31 ++++++++ 4 files changed, 134 insertions(+), 19 deletions(-) create mode 100644 gnu/packages/patches/ghc-pandoc-fix-html-tests.patch create mode 100644 gnu/packages/patches/ghc-pandoc-fix-latex-test.patch diff --git a/gnu/local.mk b/gnu/local.mk index fd18592582..8e937c8734 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -882,6 +882,8 @@ dist_patch_DATA = \ %D%/packages/patches/ghc-dont-pass-linker-flags-via-response-files.patch \ %D%/packages/patches/ghc-hpack-fix-tests.patch \ %D%/packages/patches/ghc-monad-par-fix-tests.patch \ + %D%/packages/patches/ghc-pandoc-fix-html-tests.patch \ + %D%/packages/patches/ghc-pandoc-fix-latex-test.patch \ %D%/packages/patches/ghostscript-no-header-id.patch \ %D%/packages/patches/ghostscript-no-header-uuid.patch \ %D%/packages/patches/ghostscript-no-header-creationdate.patch \ diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index b35452c60c..aec3950e5d 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -7638,30 +7638,18 @@ command line options in Haskell.") (define-public ghc-pandoc (package (name "ghc-pandoc") - (version "2.2.1") + (version "2.7.3") (source (origin (method url-fetch) (uri (string-append "https://hackage.haskell.org/package/pandoc/pandoc-" version ".tar.gz")) + (patches (search-patches "ghc-pandoc-fix-html-tests.patch" + "ghc-pandoc-fix-latex-test.patch")) (sha256 (base32 - "1dqin92w513l7whg5wdgrngnxsj5mb8gppfvn7kjgyv2pdgpy0zy")))) + "0dpjrr40h54cljzhvixyym07z792a9izg6b9dmqpjlgcg4rj0xx8")))) (build-system haskell-build-system) - (arguments - `(#:phases - (modify-phases %standard-phases - (add-before 'configure 'update-constraints - (lambda _ - (substitute* "pandoc.cabal" - (("tasty >= 0\\.11 && < 1\\.1") - "tasty >= 0.11 && < 1.1.1")))) - (add-before 'configure 'patch-tests - (lambda _ - ;; These tests fail benignly and have been adjusted upstream: - ;; . - (substitute* "test/Tests/Old.hs" - (("lhsWriterTests \"html\"") "[]"))))))) (inputs `(("ghc-aeson" ,ghc-aeson) ("ghc-aeson-pretty" ,ghc-aeson-pretty) @@ -7670,22 +7658,23 @@ command line options in Haskell.") ("ghc-blaze-markup" ,ghc-blaze-markup) ("ghc-cmark-gfm" ,ghc-cmark-gfm) ("ghc-data-default" ,ghc-data-default) - ("ghc-deepseq-generics" ,ghc-deepseq-generics) ("ghc-diff" ,ghc-diff) ("ghc-doctemplates" ,ghc-doctemplates) ("ghc-executable-path" ,ghc-executable-path) ("ghc-glob" ,ghc-glob) ("ghc-haddock-library" ,ghc-haddock-library) ("ghc-hslua" ,ghc-hslua) + ("ghc-hslua-module-system" ,ghc-hslua-module-system) ("ghc-hslua-module-text" ,ghc-hslua-module-text) + ("ghc-hsyaml" ,ghc-hsyaml) ("ghc-http" ,ghc-http) ("ghc-http-client" ,ghc-http-client) ("ghc-http-client-tls" ,ghc-http-client-tls) ("ghc-http-types" ,ghc-http-types) + ("ghc-ipynb" ,ghc-ipynb) ("ghc-juicypixels" ,ghc-juicypixels) ("ghc-network" ,ghc-network) ("ghc-network-uri" ,ghc-network-uri) - ("ghc-old-locale" ,ghc-old-locale) ("ghc-pandoc-types" ,ghc-pandoc-types) ("ghc-random" ,ghc-random) ("ghc-scientific" ,ghc-scientific) @@ -7696,16 +7685,17 @@ command line options in Haskell.") ("ghc-tagsoup" ,ghc-tagsoup) ("ghc-temporary" ,ghc-temporary) ("ghc-texmath" ,ghc-texmath) + ("ghc-unicode-transforms" ,ghc-unicode-transforms) ("ghc-unordered-containers" ,ghc-unordered-containers) ("ghc-vector" ,ghc-vector) ("ghc-xml" ,ghc-xml) - ("ghc-yaml" ,ghc-yaml) ("ghc-zip-archive" ,ghc-zip-archive) ("ghc-zlib" ,ghc-zlib))) (native-inputs `(("ghc-tasty" ,ghc-tasty) ("ghc-tasty-golden" ,ghc-tasty-golden) ("ghc-tasty-hunit" ,ghc-tasty-hunit) + ("ghc-tasty-lua" ,ghc-tasty-lua) ("ghc-tasty-quickcheck" ,ghc-tasty-quickcheck) ("ghc-quickcheck" ,ghc-quickcheck) ("ghc-hunit" ,ghc-hunit))) diff --git a/gnu/packages/patches/ghc-pandoc-fix-html-tests.patch b/gnu/packages/patches/ghc-pandoc-fix-html-tests.patch new file mode 100644 index 0000000000..b624ff9e9e --- /dev/null +++ b/gnu/packages/patches/ghc-pandoc-fix-html-tests.patch @@ -0,0 +1,92 @@ +This patch is taken from upstream. It fixes two HTML tests that are broken +due to using a Skylighting version greater than or equal to 0.8.2. + +From 968d2046a3cb6db661673be580660ac402753c34 Mon Sep 17 00:00:00 2001 +From: John MacFarlane +Date: Sun, 14 Jul 2019 10:48:14 -0700 +Subject: [PATCH] Update test for new skylighting. + +--- + test/lhs-test.html | 13 ++++++------- + test/lhs-test.html+lhs | 13 ++++++------- + 2 files changed, 12 insertions(+), 14 deletions(-) + +diff --git a/test/lhs-test.html b/test/lhs-test.html +index 6685555f4..446dd3d95 100644 +--- a/test/lhs-test.html ++++ b/test/lhs-test.html +@@ -12,19 +12,18 @@ + div.column{display: inline-block; vertical-align: top; width: 50%;} + + +