Date: Wednesday, May 26, 2021 @ 03:02:02 Author: felixonmars Revision: 946437
archrelease: copy trunk to community-staging-x86_64 Added: haskell-file-embed/repos/community-staging-x86_64/ haskell-file-embed/repos/community-staging-x86_64/PKGBUILD (from rev 946436, haskell-file-embed/trunk/PKGBUILD) ----------+ PKGBUILD | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) Copied: haskell-file-embed/repos/community-staging-x86_64/PKGBUILD (from rev 946436, haskell-file-embed/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2021-05-26 03:02:02 UTC (rev 946437) @@ -0,0 +1,43 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Arch Haskell Team <arch-hask...@haskell.org> + +_hkgname=file-embed +pkgname=haskell-file-embed +pkgver=0.0.14.0 +pkgrel=1 +pkgdesc="Use Template Haskell to embed file contents directly." +url="https://github.com/snoyberg/file-embed" +license=("BSD") +arch=('x86_64') +depends=('ghc-libs') +makedepends=('ghc') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('e87bcec045217ab0d463ab4a6ff38f43500fe979eb47b43d568873376f3cc43eb743b8e71c6b73b288eaf492c2e469914abe40be506465047390d216c86dafce') + +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 + runhaskell Setup build $MAKEFLAGS + 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 --show-details=direct +} + +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 +}