diff options
-rw-r--r-- | .SRCINFO | 14 | ||||
-rw-r--r-- | PKGBUILD | 45 |
2 files changed, 59 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..24f9cf11c511 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,14 @@ +pkgbase = haskell-boolean + pkgdesc = Vector & affine spaces, linear maps, and derivatives + pkgver = 0.2.4 + pkgrel = 1 + url = https://github.com/conal/Boolean + arch = x86_64 + license = BSD + makedepends = ghc + depends = ghc-libs + source = https://hackage.haskell.org/packages/archive/Boolean/0.2.4/Boolean-0.2.4.tar.gz + sha256sums = 67216013b02b8ac5b534a1ef25f409f930eea1a85eae801933a01ad43145eef8 + +pkgname = haskell-boolean + diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..31a5df71abad --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,45 @@ +# Maintainer: Daniel Mouritzen <dmrtzn at gmail dot com> + +_hkgname=Boolean +pkgname=haskell-boolean +pkgver=0.2.4 +pkgrel=1 +pkgdesc="Vector & affine spaces, linear maps, and derivatives" +url="https://github.com/conal/Boolean" +license=("BSD") +arch=('x86_64') +depends=('ghc-libs') +makedepends=('ghc') +source=("https://hackage.haskell.org/packages/archive/${_hkgname}/${pkgver}/${_hkgname}-${pkgver}.tar.gz") +sha256sums=('67216013b02b8ac5b534a1ef25f409f930eea1a85eae801933a01ad43145eef8') + +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=-optl-Wl\,-z\,relro\,-z\,now \ + --ghc-option='-pie' + + 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 +} + +check() { + cd "$_hkgname-$pkgver" + runhaskell Setup test +} + +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 "COPYING" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE" + rm -f "${pkgdir}/usr/share/doc/${pkgname}/LICENSE" +} |