1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
3 _hkgname=skylighting-core
4 pkgname=haskell-skylighting-core
7 pkgdesc="Syntax highlighting library"
8 url="https://github.com/jgm/skylighting"
11 depends=('ghc-libs' 'haskell-aeson' 'haskell-attoparsec' 'haskell-base64-bytestring'
12 'haskell-case-insensitive' 'haskell-colour' 'haskell-safe' 'haskell-utf8-string'
13 'haskell-xml-conduit')
14 makedepends=('ghc' 'haskell-diff' 'haskell-pretty-show' 'haskell-quickcheck' 'haskell-tasty'
15 'haskell-tasty-golden' 'haskell-tasty-hunit' 'haskell-tasty-quickcheck')
16 source=(https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz)
17 sha512sums=('c95d5ccc2d62f151b61402c28319100c97d6db287444f48c6e044cf513a156a784da1a2dd65043a71c188f8b8a4273f1a4b73b8ba814350fe076c2214d97ea81')
22 runhaskell Setup configure -O --enable-shared --enable-executable-dynamic --disable-library-vanilla \
23 --prefix=/usr --docdir=/usr/share/doc/$pkgname --datasubdir=$pkgname --enable-tests \
24 --dynlibdir=/usr/lib --libsubdir=\$compiler/site-local/\$pkgid --ghc-option=-fllvm \
26 runhaskell Setup build $MAKEFLAGS
27 runhaskell Setup register --gen-script
28 runhaskell Setup unregister --gen-script
29 sed -i -r -e "s|ghc-pkg.*update[^ ]* |&'--force' |" register.sh
30 sed -i -r -e "s|ghc-pkg.*unregister[^ ]* |&'--force' |" unregister.sh
35 runhaskell Setup test --show-details=direct
41 install -D -m744 register.sh "$pkgdir"/usr/share/haskell/register/$pkgname.sh
42 install -D -m744 unregister.sh "$pkgdir"/usr/share/haskell/unregister/$pkgname.sh
43 runhaskell Setup copy --destdir="$pkgdir"
44 install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
45 rm -f "$pkgdir"/usr/share/doc/$pkgname/LICENSE