Date: Wednesday, August 31, 2022 @ 20:33:00 Author: felixonmars Revision: 1289412
archrelease: copy trunk to community-staging-x86_64 Added: haskell-wai-middleware-static/repos/community-staging-x86_64/ haskell-wai-middleware-static/repos/community-staging-x86_64/PKGBUILD (from rev 1289411, haskell-wai-middleware-static/trunk/PKGBUILD) ----------+ PKGBUILD | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) Copied: haskell-wai-middleware-static/repos/community-staging-x86_64/PKGBUILD (from rev 1289411, haskell-wai-middleware-static/trunk/PKGBUILD) =================================================================== --- community-staging-x86_64/PKGBUILD (rev 0) +++ community-staging-x86_64/PKGBUILD 2022-08-31 20:33:00 UTC (rev 1289412) @@ -0,0 +1,52 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Arch Haskell Team <arch-hask...@haskell.org> + +_hkgname=wai-middleware-static +pkgname=haskell-wai-middleware-static +pkgver=0.9.2 +pkgrel=81 +pkgdesc="WAI middleware that serves requests to static files" +url="https://github.com/scotty-web/wai-middleware-static" +license=("BSD") +arch=('x86_64') +depends=('ghc-libs' 'haskell-base16-bytestring' 'haskell-cryptohash-sha1' + 'haskell-expiring-cache-map' 'haskell-http-types' 'haskell-mime-types' + 'haskell-old-locale' 'haskell-wai') +makedepends=('ghc' 'uusi' 'haskell-hspec' 'haskell-hspec-discover' + 'haskell-hspec-expectations-lifted' 'haskell-hspec-wai' 'haskell-mockery' + 'haskell-scotty' 'haskell-wai-extra') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha512sums=('fbfb57a64b9eabce3196c97a1727a533d9dc71fdf3e3a2316e6eb5edffc26b7c7f091b0ebc9144c129d3ec6bc452ddb846ef15e898d62507b4170f5354188be8') + +prepare() { + cd $_hkgname-$pkgver + uusi -d semigroups $_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 --datasubdir=$pkgname --enable-tests \ + --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid --ghc-option=-fllvm + 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 +}