[arch-commits] Commit in haskell-haddock-api/repos (6 files)

Sergej Pupykin spupykin at archlinux.org
Tue Dec 30 22:46:22 UTC 2014


    Date: Tuesday, December 30, 2014 @ 23:46:21
  Author: spupykin
Revision: 125048

archrelease: copy trunk to community-staging-i686, community-staging-x86_64

Added:
  haskell-haddock-api/repos/community-staging-i686/
  haskell-haddock-api/repos/community-staging-i686/PKGBUILD
    (from rev 125047, haskell-haddock-api/trunk/PKGBUILD)
  haskell-haddock-api/repos/community-staging-i686/haskell-haddock-api.install
    (from rev 125047, haskell-haddock-api/trunk/haskell-haddock-api.install)
  haskell-haddock-api/repos/community-staging-x86_64/
  haskell-haddock-api/repos/community-staging-x86_64/PKGBUILD
    (from rev 125047, haskell-haddock-api/trunk/PKGBUILD)
  haskell-haddock-api/repos/community-staging-x86_64/haskell-haddock-api.install
    (from rev 125047, haskell-haddock-api/trunk/haskell-haddock-api.install)

------------------------------------------------------+
 community-staging-i686/PKGBUILD                      |   57 +++++++++++++++++
 community-staging-i686/haskell-haddock-api.install   |   20 +++++
 community-staging-x86_64/PKGBUILD                    |   57 +++++++++++++++++
 community-staging-x86_64/haskell-haddock-api.install |   20 +++++
 4 files changed, 154 insertions(+)

Copied: haskell-haddock-api/repos/community-staging-i686/PKGBUILD (from rev 125047, haskell-haddock-api/trunk/PKGBUILD)
===================================================================
--- community-staging-i686/PKGBUILD	                        (rev 0)
+++ community-staging-i686/PKGBUILD	2014-12-30 22:46:21 UTC (rev 125048)
@@ -0,0 +1,57 @@
+# $Id$
+# Maintainer: Sergej Pupykin <arch+pub at sergej.pp.ru>
+
+pkgname=haskell-haddock-api
+pkgver=2.15.0.1
+pkgrel=3
+pkgdesc="A documentation-generation tool for Haskell libraries"
+url="http://www.haskell.org/haddock/"
+license=("BSD3")
+arch=('i686' 'x86_64')
+makedepends=()
+depends=("ghc"
+         "haskell-ghc-paths"
+         "haskell-haddock-library")
+options=('strip' 'staticlibs')
+source=("http://hackage.haskell.org/packages/archive/haddock-api/${pkgver}/haddock-api-${pkgver}.tar.gz")
+install="${pkgname}.install"
+sha256sums=("551b4485663f86528ebc8c9a268eee97342f83ff07e863226449cdd2a6e745e8")
+
+build() {
+    cd "${srcdir}/haddock-api-${pkgver}"
+
+    runhaskell Setup configure -O --enable-library-profiling --enable-shared \
+        --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+        --libsubdir=\$compiler/site-local/\$pkgid
+    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.*unregister[^ ]* |&'--force' |" unregister.sh
+}
+
+_update_deps() {
+    _ver=`pacman -Q $1 | cut -f2 -d\  | cut -f1 -d-`
+    for i in `seq 0 $(expr ${#depends[@]} - 1)`; do
+        if [ ${depends[$i]} == $1 ]; then
+            depends[$i]="$1=${_ver}"
+        fi
+    done
+}
+
+
+package() {
+    cd "${srcdir}/haddock-api-${pkgver}"
+
+    _update_deps ghc
+    _update_deps haskell-ghc-paths
+    _update_deps haskell-haddock-library
+
+    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/haddock-api"
+    runhaskell Setup copy --destdir="${pkgdir}"
+    install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+    rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE"
+}

Copied: haskell-haddock-api/repos/community-staging-i686/haskell-haddock-api.install (from rev 125047, haskell-haddock-api/trunk/haskell-haddock-api.install)
===================================================================
--- community-staging-i686/haskell-haddock-api.install	                        (rev 0)
+++ community-staging-i686/haskell-haddock-api.install	2014-12-30 22:46:21 UTC (rev 125048)
@@ -0,0 +1,20 @@
+# custom variables
+pkgname=haskell-haddock-api
+HS_DIR=usr/share/haskell/${pkgname}
+
+# functions
+post_install() {
+    ${HS_DIR}/register.sh
+}
+
+pre_upgrade() {
+    ${HS_DIR}/unregister.sh
+}
+
+post_upgrade() {
+    ${HS_DIR}/register.sh
+}
+
+pre_remove() {
+    ${HS_DIR}/unregister.sh
+}

Copied: haskell-haddock-api/repos/community-staging-x86_64/PKGBUILD (from rev 125047, haskell-haddock-api/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2014-12-30 22:46:21 UTC (rev 125048)
@@ -0,0 +1,57 @@
+# $Id$
+# Maintainer: Sergej Pupykin <arch+pub at sergej.pp.ru>
+
+pkgname=haskell-haddock-api
+pkgver=2.15.0.1
+pkgrel=3
+pkgdesc="A documentation-generation tool for Haskell libraries"
+url="http://www.haskell.org/haddock/"
+license=("BSD3")
+arch=('i686' 'x86_64')
+makedepends=()
+depends=("ghc"
+         "haskell-ghc-paths"
+         "haskell-haddock-library")
+options=('strip' 'staticlibs')
+source=("http://hackage.haskell.org/packages/archive/haddock-api/${pkgver}/haddock-api-${pkgver}.tar.gz")
+install="${pkgname}.install"
+sha256sums=("551b4485663f86528ebc8c9a268eee97342f83ff07e863226449cdd2a6e745e8")
+
+build() {
+    cd "${srcdir}/haddock-api-${pkgver}"
+
+    runhaskell Setup configure -O --enable-library-profiling --enable-shared \
+        --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \
+        --libsubdir=\$compiler/site-local/\$pkgid
+    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.*unregister[^ ]* |&'--force' |" unregister.sh
+}
+
+_update_deps() {
+    _ver=`pacman -Q $1 | cut -f2 -d\  | cut -f1 -d-`
+    for i in `seq 0 $(expr ${#depends[@]} - 1)`; do
+        if [ ${depends[$i]} == $1 ]; then
+            depends[$i]="$1=${_ver}"
+        fi
+    done
+}
+
+
+package() {
+    cd "${srcdir}/haddock-api-${pkgver}"
+
+    _update_deps ghc
+    _update_deps haskell-ghc-paths
+    _update_deps haskell-haddock-library
+
+    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/haddock-api"
+    runhaskell Setup copy --destdir="${pkgdir}"
+    install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+    rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE"
+}

Copied: haskell-haddock-api/repos/community-staging-x86_64/haskell-haddock-api.install (from rev 125047, haskell-haddock-api/trunk/haskell-haddock-api.install)
===================================================================
--- community-staging-x86_64/haskell-haddock-api.install	                        (rev 0)
+++ community-staging-x86_64/haskell-haddock-api.install	2014-12-30 22:46:21 UTC (rev 125048)
@@ -0,0 +1,20 @@
+# custom variables
+pkgname=haskell-haddock-api
+HS_DIR=usr/share/haskell/${pkgname}
+
+# functions
+post_install() {
+    ${HS_DIR}/register.sh
+}
+
+pre_upgrade() {
+    ${HS_DIR}/unregister.sh
+}
+
+post_upgrade() {
+    ${HS_DIR}/register.sh
+}
+
+pre_remove() {
+    ${HS_DIR}/unregister.sh
+}



More information about the arch-commits mailing list