[arch-commits] Commit in haskell-hie-bios/repos (2 files)
Felix Yan
felixonmars at gemini.archlinux.org
Sun Aug 21 08:18:54 UTC 2022
Date: Sunday, August 21, 2022 @ 08:18:54
Author: felixonmars
Revision: 1271906
archrelease: copy trunk to community-staging-x86_64
Added:
haskell-hie-bios/repos/community-staging-x86_64/
haskell-hie-bios/repos/community-staging-x86_64/PKGBUILD
(from rev 1271905, haskell-hie-bios/trunk/PKGBUILD)
----------+
PKGBUILD | 72 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 72 insertions(+)
Copied: haskell-hie-bios/repos/community-staging-x86_64/PKGBUILD (from rev 1271905, haskell-hie-bios/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD (rev 0)
+++ community-staging-x86_64/PKGBUILD 2022-08-21 08:18:54 UTC (rev 1271906)
@@ -0,0 +1,72 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+_hkgname=hie-bios
+pkgname=haskell-hie-bios
+pkgver=0.8.0
+pkgrel=7
+pkgdesc="Set up a GHC API session"
+url="https://github.com/mpickering/hie-bios"
+license=("BSD")
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-aeson' 'haskell-base16-bytestring' 'haskell-conduit'
+ 'haskell-conduit-extra' 'haskell-cryptohash-sha1' 'haskell-exceptions' 'haskell-extra'
+ 'haskell-file-embed' 'haskell-ghc-api-compat' 'haskell-hslogger'
+ 'haskell-optparse-applicative' 'haskell-temporary' 'haskell-unix-compat'
+ 'haskell-unordered-containers' 'haskell-vector' 'haskell-yaml')
+makedepends=('ghc' 'uusi' 'haskell-hspec-expectations' 'haskell-tasty' 'haskell-tasty-expected-failure'
+ 'haskell-tasty-hunit')
+checkdepends=('cabal-install')
+source=("https://hackage.haskell.org/packages/archive/$_hkgname/$pkgver/$_hkgname-$pkgver.tar.gz"
+ $pkgname-ghc-9.0.2.patch::https://github.com/haskell/hie-bios/commit/da0cb23384cc6e9b393792f8f25a3c174a4edafa.patch)
+sha512sums=('24b62d89a64824c05a0c397cdfa853b43123cf6ea4f053fa8b66692e28dbea6f62542290b15234bdfff10f72d339fc7cac6504c3ff4c20ab9ba5fb8b54ff39ed'
+ '5fa94f58c47d8597a8b797ea526422463569983332e1acd1769e6d67fd85dcbaea1b8ad2ba72f11f9755aaa49a101f4ad601ce5121756638df7ee6e478619885')
+
+prepare() {
+ cd $_hkgname-$pkgver
+
+ uusi -u unix-compat $_hkgname.cabal
+
+ patch -Np1 -i ../$pkgname-ghc-9.0.2.patch
+
+ # It is broken only in the hackage tarball
+ sed -i 's/FilePah/FilePath/' tests/ParserTests.hs
+
+ # Additional fixes for dynamic ghc
+ sed -i 's/updateWays \.//' src/HIE/Bios/Environment.hs
+
+ # https://github.com/mpickering/hie-bios/issues/290
+ chmod +x tests/projects/*/*.sh
+}
+
+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 \
+ --ghc-option=-optl-Wl\,-z\,relro\,-z\,now \
+ --ghc-option='-pie'
+
+ 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
+ cabal update # Generate cabal config for tests
+ # Test failures are related to process-1.6.13
+ runhaskell Setup test --show-details=direct || echo "Tests failed"
+}
+
+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