Date: Monday, May 27, 2019 @ 17:34:20 Author: felixonmars Revision: 471727
archrelease: copy trunk to community-staging-x86_64 Added: haskell-text-short/repos/community-staging-x86_64/ haskell-text-short/repos/community-staging-x86_64/PKGBUILD (from rev 471726, haskell-text-short/trunk/PKGBUILD) ----------+ PKGBUILD | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) Copied: haskell-text-short/repos/community-staging-x86_64/PKGBUILD (from rev 471726, haskell-text-short/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2019-05-27 17:34:20 UTC (rev 471727) @@ -0,0 +1,50 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Arch Haskell Team <arch-hask...@haskell.org> + +_hkgname=text-short +pkgname=haskell-text-short +pkgver=0.1.2 +pkgrel=52 +pkgdesc="Memory-efficient representation of Unicode text strings" +url="https://github.com/hvr/text-short" +license=("BSD") +arch=('x86_64') +depends=('ghc-libs' 'haskell-hashable') +makedepends=('ghc' 'haskell-quickcheck-instances' 'haskell-tasty' 'haskell-tasty-hunit' + 'haskell-tasty-quickcheck') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('f0d454f4146bfa220ff02e9e76ae366c5f6d5b4253296e8f96299ed3f30b9b982d5daca6f50b0681b6ccf5fba7103914f6a8688d0da89740dcd71d1eda9c9851') + +prepare() { + cd $_hkgname-$pkgver + sed -i -e 's/<.*1.1/<2/' -e 's/< *4.12/<5/' $_hkgname.cabal +} + +build() { + cd $_hkgname-$pkgver + + runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \ + --prefix=/usr --docdir=/usr/share/doc/$pkgname --enable-tests \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid \ + -f-asserts + runhaskell Setup build + 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 +} + +check() { + cd $_hkgname-$pkgver + runhaskell Setup test +} + +package() { + cd $_hkgname-$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 + runhaskell Setup copy --destdir="$pkgdir" + install -D -m644 "LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE" +}