[arch-commits] Commit in pandoc/trunk (PKGBUILD haskell-pandoc.install pandoc.install)

Felix Yan fyan at archlinux.org
Fri Dec 25 04:10:54 UTC 2015


    Date: Friday, December 25, 2015 @ 05:10:54
  Author: fyan
Revision: 154464

upgpkg: pandoc 1.15.2.1-14

split docs and libraries

Added:
  pandoc/trunk/haskell-pandoc.install
    (from rev 154463, pandoc/trunk/pandoc.install)
Modified:
  pandoc/trunk/PKGBUILD
Deleted:
  pandoc/trunk/pandoc.install

------------------------+
 PKGBUILD               |   55 ++++++++++++++++++++++++++---------------------
 haskell-pandoc.install |   18 +++++++++++++++
 pandoc.install         |   18 ---------------
 3 files changed, 49 insertions(+), 42 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2015-12-25 02:43:36 UTC (rev 154463)
+++ PKGBUILD	2015-12-25 04:10:54 UTC (rev 154464)
@@ -2,27 +2,26 @@
 # Maintainer: Felix Yan <felixonmars at archlinux.org>
 # Contributor: Arch Haskell Team <arch-haskell at haskell.org>
 
-pkgname=pandoc
+pkgbase=pandoc
+pkgname=(pandoc haskell-pandoc)
 pkgver=1.15.2.1
-pkgrel=13
+pkgrel=14
 pkgdesc="Conversion between markup formats"
 url="http://pandoc.org"
 license=("GPL")
 arch=('i686' 'x86_64')
-depends=("ghc=7.10.3" "haskell-http" "haskell-juicypixels" "haskell-sha" "haskell-aeson"
-         "haskell-base64-bytestring" "haskell-blaze-html" "haskell-blaze-markup"
-         "haskell-cmark" "haskell-data-default" "haskell-deepseq-generics" "haskell-mtl"
-         "haskell-extensible-exceptions" "haskell-filemanip" "haskell-haddock-library"
-         "haskell-highlighting-kate" "haskell-hslua" "haskell-http-client" "haskell-syb"
-         "haskell-http-client-tls" "haskell-http-types"  "haskell-text" "haskell-texmath"
-         "haskell-network" "haskell-old-time" "haskell-pandoc-types" "haskell-parsec"
-         "haskell-random" "haskell-scientific" "haskell-tagsoup" "haskell-temporary"
-         "haskell-network-uri" "haskell-unordered-containers" "haskell-zip-archive"
-         "haskell-vector" "haskell-xml" "haskell-yaml" "haskell-zlib")
-optdepends=('haskell-pandoc-citeproc: for citation rendering with pandoc-citeproc filter')
+makedepends=("ghc=7.10.3" "haskell-http" "haskell-juicypixels" "haskell-sha" "haskell-aeson"
+             "haskell-base64-bytestring" "haskell-blaze-html" "haskell-blaze-markup"
+             "haskell-cmark" "haskell-data-default" "haskell-deepseq-generics" "haskell-mtl"
+             "haskell-extensible-exceptions" "haskell-filemanip" "haskell-haddock-library"
+             "haskell-highlighting-kate" "haskell-hslua" "haskell-http-client" "haskell-syb"
+             "haskell-http-client-tls" "haskell-http-types"  "haskell-text" "haskell-texmath"
+             "haskell-network" "haskell-old-time" "haskell-pandoc-types" "haskell-parsec"
+             "haskell-random" "haskell-scientific" "haskell-tagsoup" "haskell-temporary"
+             "haskell-network-uri" "haskell-unordered-containers" "haskell-zip-archive"
+             "haskell-vector" "haskell-xml" "haskell-yaml" "haskell-zlib")
 options=('staticlibs')
 source=("http://hackage.haskell.org/packages/archive/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz")
-install="${pkgname}.install"
 sha256sums=('60bcb0e65ecb63953dd26d5aacf1a5df83700d116062ffaeffe9edbc9be6df59')
 
 build() {
@@ -29,14 +28,12 @@
     cd "${srcdir}/${pkgname}-${pkgver}"
     
     runhaskell Setup configure -O --enable-library-profiling --enable-shared \
-        --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+        --prefix=/usr --docdir="/usr/share/doc/${pkgbase}" --datasubdir="$pkgname" \
         --libsubdir=\$compiler/site-local/\$pkgid \
             -f-old-locale -fnetwork-uri -fhttps -f-trypandoc -f-embed_data_files
     runhaskell Setup build
 
-    # LC_CTYPE=en_US.UTF-8 is needed since 1.15.1
-    # https://github.com/jgm/pandoc/issues/2457#issuecomment-149146107
-    LC_CTYPE=en_US.UTF-8 runhaskell Setup haddock --hoogle --html
+    runhaskell Setup haddock --hoogle --html
 
     runhaskell Setup register --gen-script
     runhaskell Setup unregister --gen-script
@@ -43,16 +40,26 @@
     sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
 }
 
-package() {
-    cd "${srcdir}/${pkgname}-${pkgver}"
-    
+package_pandoc() {
+    depends=('gmp' 'libffi' 'zlib')
+    optdepends=('pandoc-citeproc: for citation rendering with pandoc-citeproc filter')
+
+    cd "${srcdir}/${pkgbase}-${pkgver}"
+    runhaskell Setup copy --destdir="${pkgdir}"
+    rm -r "$pkgdir"/usr/{lib,share/doc}
+}
+
+package_haskell-pandoc() {
+    pkgdesc="Conversion between markup formats (docs and libraries)"
+    depends=("${makedepends[@]}" 'pandoc')
+    install="haskell-pandoc.install"
+
+    cd "${srcdir}/${pkgbase}-${pkgver}"    
     install -D -m744 register.sh   "${pkgdir}/usr/share/haskell/${pkgname}/register.sh"
     install    -m744 unregister.sh "${pkgdir}/usr/share/haskell/${pkgname}/unregister.sh"
-    install -d -m755 "${pkgdir}/usr/share/man/man1"
-    install -d -m755 "${pkgdir}/usr/share/man/man5"
     install -d -m755 "${pkgdir}/usr/share/doc/ghc/html/libraries"
     ln -s "/usr/share/doc/${pkgname}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${pkgname}"
     runhaskell Setup copy --destdir="${pkgdir}"
-    install -D -m644 "COPYING" "${pkgdir}/usr/share/licenses/${pkgname}/COPYING"
+    rm -r "$pkgdir"/usr/share/{pandoc,man} "$pkgdir"/usr/bin
     rm -f "${pkgdir}/usr/share/doc/${pkgname}/COPYING"
 }

Copied: pandoc/trunk/haskell-pandoc.install (from rev 154463, pandoc/trunk/pandoc.install)
===================================================================
--- haskell-pandoc.install	                        (rev 0)
+++ haskell-pandoc.install	2015-12-25 04:10:54 UTC (rev 154464)
@@ -0,0 +1,18 @@
+HS_DIR=usr/share/haskell/haskell-pandoc
+post_install() {
+  ${HS_DIR}/register.sh
+  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
+}
+pre_upgrade() {
+  ${HS_DIR}/unregister.sh
+}
+post_upgrade() {
+  ${HS_DIR}/register.sh
+  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
+}
+pre_remove() {
+  ${HS_DIR}/unregister.sh
+}
+post_remove() {
+  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
+}

Deleted: pandoc.install
===================================================================
--- pandoc.install	2015-12-25 02:43:36 UTC (rev 154463)
+++ pandoc.install	2015-12-25 04:10:54 UTC (rev 154464)
@@ -1,18 +0,0 @@
-HS_DIR=usr/share/haskell/pandoc
-post_install() {
-  ${HS_DIR}/register.sh
-  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
-}
-pre_upgrade() {
-  ${HS_DIR}/unregister.sh
-}
-post_upgrade() {
-  ${HS_DIR}/register.sh
-  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
-}
-pre_remove() {
-  ${HS_DIR}/unregister.sh
-}
-post_remove() {
-  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
-}



More information about the arch-commits mailing list