[arch-commits] Commit in haskell-extensible-exceptions/trunk (2 files)

Rémy Oudompheng remy at archlinux.org
Fri Nov 26 10:03:44 UTC 2010


    Date: Friday, November 26, 2010 @ 05:03:44
  Author: remy
Revision: 100898

upgpkg: haskell-extensible-exceptions 0.1.1.2-2
Rebuild for ghc-7.0.1, add documentation

Modified:
  haskell-extensible-exceptions/trunk/PKGBUILD
  haskell-extensible-exceptions/trunk/haskell-extensible-exceptions.install

---------------------------------------+
 PKGBUILD                              |   25 +++++++++++++++++--------
 haskell-extensible-exceptions.install |    8 ++++++--
 2 files changed, 23 insertions(+), 10 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2010-11-26 09:57:42 UTC (rev 100897)
+++ PKGBUILD	2010-11-26 10:03:44 UTC (rev 100898)
@@ -1,26 +1,35 @@
 # Maintainer: Vesa Kaihlavirta <vegai at iki.fi>
 # Contributor: Arch Haskell Team <arch-haskell at haskell.org>
-# Package generated by cabal2arch 0.4.1
+_hkgname=extensible-exceptions
 pkgname=haskell-extensible-exceptions
-pkgrel=1
 pkgver=0.1.1.2
+pkgrel=2
 pkgdesc="Extensible exceptions"
 url="http://hackage.haskell.org/cgi-bin/hackage-scripts/package/extensible-exceptions"
 license=('custom:BSD3')
 arch=('i686' 'x86_64')
-depends=('ghc=6.12.3'  sh)
+depends=('ghc=7.0.1' sh)
 options=('strip')
-source=(http://hackage.haskell.org/packages/archive/extensible-exceptions/$pkgver/extensible-exceptions-$pkgver.tar.gz)
-install=haskell-extensible-exceptions.install
+source=(http://hackage.haskell.org/packages/archive/${_hkgname}/$pkgver/${_hkgname}-$pkgver.tar.gz)
+install=${pkgname}.install
+md5sums=('8154e11e77db72b411f3854a03c5a0a3')
 build() {
-    cd ${srcdir}/extensible-exceptions-$pkgver
-    runhaskell Setup configure --prefix=/usr -p --enable-split-objs --enable-shared
+    cd ${srcdir}/${_hkgname}-$pkgver
+    runhaskell Setup configure -O -p --enable-split-objs --enable-shared --prefix=/usr --docdir=/usr/share/doc/${pkgname}
     runhaskell Setup build
+    runhaskell Setup haddock
     runhaskell Setup register   --gen-script
     runhaskell Setup unregister --gen-script
+    sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
+}
+
+package() {
+    cd ${srcdir}/${_hkgname}-${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/doc/ghc/html/libraries
+    ln -s /usr/share/doc/${pkgname}/html ${pkgdir}/usr/share/doc/ghc/html/libraries/${_hkgname}
     runhaskell Setup copy --destdir=${pkgdir}
     install -D -m644 LICENSE ${pkgdir}/usr/share/licenses/${pkgname}/LICENSE
+    rm -f ${pkgdir}/usr/share/doc/${pkgname}/LICENSE
 }
-md5sums=('8154e11e77db72b411f3854a03c5a0a3')

Modified: haskell-extensible-exceptions.install
===================================================================
--- haskell-extensible-exceptions.install	2010-11-26 09:57:42 UTC (rev 100897)
+++ haskell-extensible-exceptions.install	2010-11-26 10:03:44 UTC (rev 100898)
@@ -1,14 +1,18 @@
 HS_DIR=usr/share/haskell/haskell-extensible-exceptions
 post_install() {
   ${HS_DIR}/register.sh
+  (cd usr/share/doc/ghc/html/libraries; ./gen_contents_index)
 }
 pre_upgrade() {
-  ${HS_DIR}/unregister.sh &> /dev/null
-  exit 0
+  ${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