[arch-commits] Commit in idris/repos (2 files)

Felix Yan felixonmars at gemini.archlinux.org
Wed Aug 31 20:41:57 UTC 2022


    Date: Wednesday, August 31, 2022 @ 20:41:57
  Author: felixonmars
Revision: 1289443

archrelease: copy trunk to community-staging-x86_64

Added:
  idris/repos/community-staging-x86_64/
  idris/repos/community-staging-x86_64/PKGBUILD
    (from rev 1289442, idris/trunk/PKGBUILD)

----------+
 PKGBUILD |   60 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 60 insertions(+)

Copied: idris/repos/community-staging-x86_64/PKGBUILD (from rev 1289442, idris/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD	                        (rev 0)
+++ community-staging-x86_64/PKGBUILD	2022-08-31 20:41:57 UTC (rev 1289443)
@@ -0,0 +1,60 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Arch Haskell Team <arch-haskell at haskell.org>
+
+pkgname=idris
+pkgver=1.3.4
+pkgrel=23
+pkgdesc="Functional Programming Language with Dependent Types"
+url="https://www.idris-lang.org/"
+license=("BSD")
+arch=('x86_64')
+depends=('ghc-libs' 'haskell-aeson' 'haskell-annotated-wl-pprint' 'haskell-ansi-terminal'
+         'haskell-ansi-wl-pprint' 'haskell-async' 'haskell-base64-bytestring' 'haskell-blaze-html'
+         'haskell-blaze-markup' 'haskell-cheapskate' 'haskell-code-page' 'haskell-fingertree'
+         'haskell-fsnotify' 'haskell-ieee754' 'haskell-libffi' 'haskell-megaparsec'
+         'haskell-network' 'haskell-optparse-applicative' 'haskell-parser-combinators'
+         'haskell-regex-tdfa' 'haskell-safe' 'haskell-split' 'haskell-terminal-size'
+         'haskell-uniplate' 'haskell-unordered-containers' 'haskell-utf8-string' 'haskell-vector'
+         'haskell-vector-binary-instances' 'haskell-zip-archive')
+makedepends=('ghc' 'uusi' 'haskell-tagged' 'haskell-tasty' 'haskell-tasty-golden' 'haskell-tasty-rerun'
+             'nodejs')
+source=("https://github.com/idris-lang/Idris-dev/archive/v$pkgver/$pkgname-$pkgver.tar.gz")
+sha512sums=('5c081c34cf09c130b213626e5cc4f85ae82fef3f7ac1c76636e497a472b31a638c829e29dfe81b9a240a068736fd27db0de592be9d1b48956b809908a913ad64')
+
+prepare() {
+    cd Idris-dev-$pkgver
+    sed -i '1ioverride IDRIS := env LD_PRELOAD=$(shell ls ../../dist/build/libHSidris-*-ghc*.so) $(IDRIS)' \
+        libs/*/Makefile
+    uusi -u Cabal -u network -u libffi idris.cabal
+}
+
+build() {
+    cd Idris-dev-$pkgver
+
+    export CFLAGS+=' -ffat-lto-objects'
+    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 \
+            -fFFI -fGMP -f-release -f-freestanding -f-CI -f-execonly --ghc-option='-pie'
+    LC_CTYPE=en_US.UTF-8 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 Idris-dev-$pkgver
+    # TODO: figure out the tests
+    PATH="$PWD/dist/build:$PWD/dist/build/idris:$PATH" LD_LIBRARY_PATH="$PWD/dist/build" IDRIS_LIBRARY_PATH="$PWD/libs" runhaskell Setup test || echo "Tests failed"
+}
+
+package() {
+    cd Idris-dev-$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
+}



More information about the arch-commits mailing list