[arch-commits] Commit in cabal-helper/trunk (PKGBUILD)
Felix Yan
fyan at archlinux.org
Wed Jan 20 16:32:37 UTC 2016
Date: Wednesday, January 20, 2016 @ 17:32:37
Author: fyan
Revision: 158319
upgpkg: cabal-helper 0.6.3.1-2
split cabal-helper-wrapper to a separate package, to be dependency of ghc-mod
Modified:
cabal-helper/trunk/PKGBUILD
----------+
PKGBUILD | 37 ++++++++++++++++++++++++-------------
1 file changed, 24 insertions(+), 13 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2016-01-20 16:17:06 UTC (rev 158318)
+++ PKGBUILD 2016-01-20 16:32:37 UTC (rev 158319)
@@ -2,25 +2,24 @@
# Maintainer: Felix Yan <felixonmars at archlinux.org>
# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
-_hkgname=cabal-helper
-pkgname=haskell-cabal-helper
+pkgbase=cabal-helper
+pkgname=(cabal-helper haskell-cabal-helper)
pkgver=0.6.3.1
-pkgrel=1
-pkgdesc="Simple interface to some of Cabal\'s configuration state used by ghc-mod"
-url="http://hackage.haskell.org/package/${_hkgname}"
+pkgrel=2
+pkgdesc="Simple interface to some of Cabals configuration state used by ghc-mod"
+url="http://hackage.haskell.org/package/${pkgbase}"
license=("AGPL3")
arch=('i686' 'x86_64')
-depends=("ghc=7.10.3" "haskell-mtl" "haskell-temporary" "haskell-utf8-string")
+makedepends=("ghc=7.10.3" "haskell-mtl" "haskell-temporary" "haskell-utf8-string")
options=('staticlibs')
-source=("http://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz")
-install="${pkgname}.install"
+source=("http://hackage.haskell.org/packages/archive/${pkgbase}/${pkgver}/${pkgbase}-${pkgver}.tar.gz")
sha256sums=('c19a9a87c54f6649e0f8cbb3a070244bff9fcc5b9ae783c00c049867fb1a7afe')
build() {
- cd "${srcdir}/${_hkgname}-${pkgver}"
+ cd "${srcdir}/${pkgbase}-${pkgver}"
runhaskell Setup configure -O --enable-library-profiling --enable-shared \
- --prefix=/usr --docdir="/usr/share/doc/${pkgname}" --libexecdir="/usr/lib" \
+ --prefix=/usr --docdir="/usr/share/doc/${pkgbase}" --libexecdir="/usr/lib" \
--libsubdir=\$compiler/site-local/\$pkgid
runhaskell Setup build
runhaskell Setup haddock --hoogle --html
@@ -29,13 +28,25 @@
sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
}
-package() {
- cd "${srcdir}/${_hkgname}-${pkgver}"
+package_cabal-helper() {
+ depends=('gmp' 'libffi')
+
+ cd "${srcdir}/${pkgbase}-${pkgver}"
+ runhaskell Setup copy --destdir="${pkgdir}"
+ rm -r "$pkgdir"/usr/{lib/ghc-*,share}
+}
+
+package_haskell-cabal-helper() {
+ pkgdesc="Simple interface to some of Cabal's configuration state used by ghc-mod (docs and libraries)"
+ depends=("${makedepends[@]}" 'cabal-helper')
+ install="haskell-cabal-helper.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/doc/ghc/html/libraries"
- ln -s "/usr/share/doc/${pkgname}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${_hkgname}"
+ ln -s "/usr/share/doc/${pkgbase}/html" "${pkgdir}/usr/share/doc/ghc/html/libraries/${pkgbase}"
runhaskell Setup copy --destdir="${pkgdir}"
rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE"
+ rm -f "$pkgdir/usr/lib/cabal-helper-wrapper"
}
More information about the arch-commits
mailing list