Date: Tuesday, May 25, 2021 @ 12:13:19 Author: felixonmars Revision: 945731
archrelease: copy trunk to community-staging-x86_64 Added: haskell-http/repos/community-staging-x86_64/ haskell-http/repos/community-staging-x86_64/PKGBUILD (from rev 945730, haskell-http/trunk/PKGBUILD) ----------+ PKGBUILD | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) Copied: haskell-http/repos/community-staging-x86_64/PKGBUILD (from rev 945730, haskell-http/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2021-05-25 12:13:19 UTC (rev 945731) @@ -0,0 +1,53 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Thomas Dziedzic <gos...@gmail.com> + +_hkgname=HTTP +pkgname=haskell-http +pkgver=4000.3.16 +pkgrel=27 +pkgdesc="A library for client-side HTTP" +url="https://hackage.haskell.org/package/${_hkgname}" +license=('BSD') +arch=('x86_64') +depends=('ghc-libs' 'haskell-network' 'haskell-network-uri') +makedepends=('ghc' 'haskell-hunit' 'haskell-httpd-shed' 'haskell-puremd5' 'haskell-split' + 'haskell-test-framework' 'haskell-test-framework-hunit' 'haskell-case-insensitive' + 'haskell-http-types' 'haskell-wai' 'haskell-warp' 'haskell-conduit' + 'haskell-conduit-extra') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('b5136b55967d4db7569a0269b429c8e419878acc548d962af94efa5aa0ddbb8a6ab22bc3096ce3d78b61dc708996c408d4bfa55c6c7fb6c0d915389503cbd755') + +build() { + cd $_hkgname-$pkgver + + if (( CHECKFUNC )); then + _opts=('--enable-tests') + else + _opts=('--disable-tests') + fi + + runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \ + --prefix=/usr --docdir=/usr/share/doc/$pkgname "${_opts[@]}" \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid \ + -f-mtl1 -f-warn-as-error -f-conduit10 -fwarp-tests -fnetwork-uri + 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 +}