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

Felix Yan felixonmars at archlinux.org
Sat Jun 17 16:29:10 UTC 2017


    Date: Saturday, June 17, 2017 @ 16:29:10
  Author: felixonmars
Revision: 237963

upgpkg: hasktags 0.69.3-3

rebuild with ghc,8.0.2

Modified:
  hasktags/trunk/PKGBUILD

----------+
 PKGBUILD |   23 ++++++++++++++++++-----
 1 file changed, 18 insertions(+), 5 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2017-06-17 16:07:42 UTC (rev 237962)
+++ PKGBUILD	2017-06-17 16:29:10 UTC (rev 237963)
@@ -4,13 +4,12 @@
 
 pkgname=hasktags
 pkgver=0.69.3
-pkgrel=2
+pkgrel=3
 pkgdesc="Produces ctags \"tags\" and etags \"TAGS\" files for Haskell programs"
 url="http://github.com/MarcWeber/hasktags"
 license=("custom:BSD3")
 arch=('i686' 'x86_64')
-depends=('gmp' 'libffi')
-makedepends=("ghc=8.0.1" "haskell-hunit" "haskell-json" "haskell-utf8-string")
+depends=("ghc" "haskell-hunit" "haskell-json" "haskell-utf8-string")
 source=("https://hackage.haskell.org/packages/archive/${pkgname}/${pkgver}/${pkgname}-${pkgver}.tar.gz")
 sha256sums=('4e069aa63c2a7d762332d1acbc12a3d705abdc5e24c06d55129e1a3fd66e5afa')
 
@@ -17,15 +16,29 @@
 build() {
     cd "${srcdir}/${pkgname}-${pkgver}"
     
-    runhaskell Setup configure -O --prefix=/usr \
+    runhaskell Setup configure -O --enable-shared --enable-executable-dynamic \
+        --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+        --libsubdir=\$compiler/site-local/\$pkgid \
             -f-debug
     runhaskell Setup build
+    runhaskell Setup haddock --hoogle --html
+    runhaskell Setup register --gen-script
+    runhaskell Setup unregister --gen-script
+    sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh
+    sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
 }
 
 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/${pkgname}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${pkgname}"
     runhaskell Setup copy --destdir="${pkgdir}"
     install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+    rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE"
 
-    rm -r "$pkgdir"/usr/{lib,share/doc}
+    # Remove static libs
+    find "$pkgdir"/usr/lib -name "*.a" -delete
 }



More information about the arch-commits mailing list