[arch-commits] Commit in pandoc-crossref/trunk (PKGBUILD)

Felix Yan felixonmars at archlinux.org
Sat Jun 17 14:54:42 UTC 2017


    Date: Saturday, June 17, 2017 @ 14:54:41
  Author: felixonmars
Revision: 237921

upgpkg: pandoc-crossref 0.2.5.0-60

rebuild with ghc,8.0.2

Modified:
  pandoc-crossref/trunk/PKGBUILD

----------+
 PKGBUILD |   46 +++++++++++++++++++---------------------------
 1 file changed, 19 insertions(+), 27 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-06-17 14:54:30 UTC (rev 237920)
+++ PKGBUILD	2017-06-17 14:54:41 UTC (rev 237921)
@@ -2,29 +2,30 @@
 # Maintainer: Felix Yan <felixonmars at archlinux.org>
 # Contributor: Arch Haskell Team <arch-haskell at haskell.org>
 
-pkgbase=pandoc-crossref
-pkgname=(pandoc-crossref haskell-pandoc-crossref)
+pkgname=pandoc-crossref
 pkgver=0.2.5.0
-pkgrel=59
+pkgrel=60
 pkgdesc="Pandoc filter for cross-references"
-url="https://hackage.haskell.org/package/${pkgbase}"
+url="https://hackage.haskell.org/package/${pkgname}"
 license=("GPL2")
 arch=('i686' 'x86_64')
-makedepends=("ghc=8.0.1" "haskell-data-default" "haskell-data-accessor" "haskell-data-accessor-template"
-             "haskell-data-accessor-transformers" "haskell-mtl" "haskell-pandoc" "haskell-pandoc-types"
-             "haskell-roman-numerals" "haskell-syb" "haskell-utility-ht")
-source=("https://hackage.haskell.org/packages/archive/${pkgbase}/${pkgver}/${pkgbase}-${pkgver}.tar.gz")
+depends=("ghc" "haskell-data-default" "haskell-data-accessor" "haskell-data-accessor-template"
+         "haskell-data-accessor-transformers" "haskell-mtl" "pandoc" "haskell-pandoc-types"
+         "haskell-roman-numerals" "haskell-syb" "haskell-utility-ht")
+conflicts=('haskell-pandoc-crossref')
+replaces=('haskell-pandoc-crossref')
+source=("https://hackage.haskell.org/packages/archive/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz")
 sha256sums=('d4d93bbe448e2cf187a0b7bcc605d0445e28021e4e31bfef890b93bee2b28491')
 
 prepare() {
-    sed -i 's/pandoc >= 1.17.1 && <1.19/pandoc >= 1.17.1 \&\& <1.20/' ${pkgbase}-${pkgver}/${pkgbase}.cabal
+    sed -i 's/pandoc >= 1.17.1 && <1.19/pandoc >= 1.17.1 \&\& <1.20/' ${pkgname}-${pkgver}/${pkgname}.cabal
 }
 
 build() {
-    cd "${srcdir}/${pkgbase}-${pkgver}"
+    cd "${srcdir}/${pkgname}-${pkgver}"
     
-    runhaskell Setup configure -O --enable-library-profiling --enable-shared \
-        --prefix=/usr --docdir="/usr/share/doc/${pkgbase}" --datasubdir="$pkgname" \
+    runhaskell Setup configure -O --enable-shared --enable-executable-dynamic \
+        --prefix=/usr --docdir="/usr/share/doc/${pkgname}" --datasubdir="$pkgname" \
         --libsubdir=\$compiler/site-local/\$pkgid
     runhaskell Setup build
     runhaskell Setup haddock --hoogle --html
@@ -34,25 +35,16 @@
     sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
 }
 
-package_pandoc-crossref() {
-    depends=('pandoc')
-
-    cd "${srcdir}/${pkgbase}-${pkgver}"
-    runhaskell Setup copy --destdir="${pkgdir}"
-    rm -r "$pkgdir"/usr/{lib,share}
-}
-
-package_haskell-pandoc-crossref() {
-    pkgdesc="Pandoc filter for cross-references (docs and libraries)"
-    depends=("${makedepends[@]}" 'pandoc-crossref')
-
-    cd "${srcdir}/${pkgbase}-${pkgver}"
+package() {
+    cd "${srcdir}/${pkgname}-${pkgver}"
     
     install -D -m744 register.sh   "${pkgdir}/usr/share/haskell/register/${pkgname}.sh"
     install -D -m744 unregister.sh "${pkgdir}/usr/share/haskell/unregister/${pkgname}.sh"
     install -d -m755 "${pkgdir}/usr/share/doc/ghc/html/libraries"
-    ln -s "/usr/share/doc/${pkgbase}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${pkgname}"
+    ln -s "/usr/share/doc/${pkgname}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${pkgname}"
     runhaskell Setup copy --destdir="${pkgdir}"
-    rm -r "$pkgdir"/usr/bin
     rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE.md"
+
+    # Remove static libs
+    find "$pkgdir"/usr/lib -name "*.a" -delete
 }



More information about the arch-commits mailing list