Date: Friday, January 19, 2018 @ 20:49:41 Author: felixonmars Revision: 284207
archrelease: copy trunk to community-staging-x86_64 Added: haskell-rebase/repos/community-staging-x86_64/ haskell-rebase/repos/community-staging-x86_64/PKGBUILD (from rev 284206, haskell-rebase/trunk/PKGBUILD) ----------+ PKGBUILD | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) Copied: haskell-rebase/repos/community-staging-x86_64/PKGBUILD (from rev 284206, haskell-rebase/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2018-01-19 20:49:41 UTC (rev 284207) @@ -0,0 +1,53 @@ +# $Id$ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Arch Haskell Team <arch-hask...@haskell.org> + +_hkgname=rebase +pkgname=haskell-rebase +pkgver=1.2.2 +pkgrel=4 +pkgdesc='A more progressive alternative to the "base" package' +url="https://github.com/nikita-volkov/rebase" +license=("MIT") +arch=('x86_64') +depends=('ghc-libs' 'haskell-stm' 'haskell-hashable' 'haskell-vector' 'haskell-unordered-containers' + 'haskell-text' 'haskell-scientific' 'haskell-uuid' 'haskell-dlist' 'haskell-void' + 'haskell-bifunctors' 'haskell-profunctors' 'haskell-contravariant' + 'haskell-contravariant-extras' 'haskell-semigroups' 'haskell-semigroupoids' 'haskell-mtl' + 'haskell-either' 'haskell-base-prelude') +makedepends=('ghc') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('b40069b07ea121bfe5ce70dcace10f42898ddd7a1d33a710b67ef4bf999cfa61ec2eb4912ee72947a3f0d88876d1441c506eabf8658e66cb394c3dc4388ffa06') + +prepare() { + cd $_hkgname-$pkgver + sed -i '/fail/d' $_hkgname.cabal + + # https://github.com/nikita-volkov/rebase/issues/10 + sed -e 's/import Rebase.Data.Functor.Alt as Exports hiding ./import Rebase.Data.Functor.Alt as Exports hiding (optional, /' \ + -e 's/import Rebase.Data.Functor.Plus as Exports hiding ./import Rebase.Data.Functor.Plus as Exports hiding (optional, /' \ + -i library/Rebase/Prelude.hs +} + +build() { + cd "${srcdir}/${_hkgname}-${pkgver}" + + runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \ + --prefix=/usr --docdir="/usr/share/doc/${pkgname}" \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid + 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 +} + +package() { + cd "${srcdir}/${_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" +}