[arch-commits] Commit in (4 files)
Felix Yan
felixonmars at archlinux.org
Tue Dec 1 15:57:47 UTC 2020
Date: Tuesday, December 1, 2020 @ 15:57:47
Author: felixonmars
Revision: 767173
addpkg: haskell-hie-compat 0.1.0.0-1
Added:
haskell-hie-compat/
haskell-hie-compat/repos/
haskell-hie-compat/trunk/
haskell-hie-compat/trunk/PKGBUILD
----------+
PKGBUILD | 45 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 45 insertions(+)
Added: haskell-hie-compat/trunk/PKGBUILD
===================================================================
--- haskell-hie-compat/trunk/PKGBUILD (rev 0)
+++ haskell-hie-compat/trunk/PKGBUILD 2020-12-01 15:57:47 UTC (rev 767173)
@@ -0,0 +1,45 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=hie-compat
+pkgname=haskell-hie-compat
+pkgver=0.1.0.0
+pkgrel=1
+pkgdesc="HIE files for GHC 8.6 and other HIE file backports"
+url="https://hackage.haskell.org/package/hie-compat"
+license=("Apache")
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-ghc')
+makedepends=('ghc' 'uusi')
+source=("https://hackage.haskell.org/packages/archive/$_hkgname/$pkgver/$_hkgname-$pkgver.tar.gz")
+sha256sums=('038ecefb8e536b0902cdff1f13bc2a6781659458c10a7b4ce0f44145fd599603')
+
+prepare() {
+ cd $_hkgname-$pkgver
+ gen-setup
+}
+
+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 \
+ --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
+}
+
+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 -t "$pkgdir"/usr/share/licenses/$pkgname/
+ rm -f "$pkgdir"/usr/share/doc/$pkgname/LICENSE
+}
More information about the arch-commits
mailing list