2014-04-18 07:07:00 +08:00
|
|
|
# Maintainer: UtG <utg[dot]chakra.linux[at]gmail[dot]com>
|
|
|
|
|
|
|
|
## NOTE: when you update Haskell packages you'll have to update the entire stack to not break it ##
|
|
|
|
|
2012-06-17 10:40:50 +08:00
|
|
|
_hkgname=dataenc
|
2011-10-10 02:06:48 +08:00
|
|
|
pkgname=haskell-dataenc
|
2015-02-23 07:43:59 +08:00
|
|
|
pkgver=0.14.0.7
|
|
|
|
pkgrel=1
|
2011-10-10 02:06:48 +08:00
|
|
|
pkgdesc="Data encoding library"
|
2012-06-17 10:40:50 +08:00
|
|
|
url="http://hackage.haskell.org/package/${_hkgname}"
|
|
|
|
license=('custom:BSD3')
|
2014-04-18 07:07:00 +08:00
|
|
|
arch=('x86_64')
|
2015-02-23 07:43:59 +08:00
|
|
|
depends=('ghc')
|
2014-04-18 07:07:00 +08:00
|
|
|
options=('strip' 'staticlibs')
|
2012-06-17 10:40:50 +08:00
|
|
|
source=(http://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
|
|
|
|
install=${pkgname}.install
|
2015-02-23 07:43:59 +08:00
|
|
|
md5sums=('28491649dbeafb9512b4ea187cc6fddf')
|
2014-04-18 07:07:00 +08:00
|
|
|
|
2011-10-10 02:06:48 +08:00
|
|
|
build() {
|
2012-06-17 10:40:50 +08:00
|
|
|
cd ${srcdir}/${_hkgname}-${pkgver}
|
2014-04-18 07:07:00 +08:00
|
|
|
runhaskell Setup configure \
|
|
|
|
-O \
|
2015-02-23 07:43:59 +08:00
|
|
|
-p \
|
2014-04-18 07:07:00 +08:00
|
|
|
--enable-split-objs \
|
|
|
|
--enable-shared \
|
|
|
|
--prefix="/usr" \
|
|
|
|
--docdir="/usr/share/doc/haskell-dataenc" \
|
|
|
|
--libsubdir='$compiler/site-local/$pkgid'
|
2012-06-17 10:40:50 +08:00
|
|
|
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
|
2011-10-10 02:06:48 +08:00
|
|
|
}
|
|
|
|
package() {
|
2012-06-17 10:40:50 +08:00
|
|
|
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
|
2014-04-18 07:07:00 +08:00
|
|
|
|
|
|
|
# Documentation
|
|
|
|
ln -s "/usr/share/doc/haskell-dataenc/html" \
|
|
|
|
"${pkgdir}/usr/share/doc/ghc/html/libraries/dataenc"
|
|
|
|
|
|
|
|
# License
|
|
|
|
install -D -m644 LICENSE \
|
|
|
|
"${pkgdir}/usr/share/licenses/haskell-dataenc/LICENSE"
|
|
|
|
rm -f "${pkgdir}/usr/share/doc/haskell-dataenc/LICENSE"
|
|
|
|
|
|
|
|
runhaskell Setup copy --destdir="${pkgdir}"
|
2011-10-10 02:06:48 +08:00
|
|
|
}
|