From 57c96956efc2926808eb89aa6f2e1a6cf352a11d Mon Sep 17 00:00:00 2001 From: Kevin Mihelich Date: Fri, 18 Dec 2015 06:02:17 +0000 Subject: [PATCH] added community/swi-prolog --- community/swi-prolog/PKGBUILD | 58 +++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 community/swi-prolog/PKGBUILD diff --git a/community/swi-prolog/PKGBUILD b/community/swi-prolog/PKGBUILD new file mode 100644 index 000000000..a3414d582 --- /dev/null +++ b/community/swi-prolog/PKGBUILD @@ -0,0 +1,58 @@ +# $Id$ +# Maintainer: Alexander Rødseth +# Contributor: Jachym Barvinek +# Contributor: Thomas Dziedzic < gostrc at gmail > +# Contributor: John Proctor +# Contributor: Juergen Hoetzel + +# ALARM: Kevin Mihelich +# - build aarch64 with -fPIC + +pkgname=swi-prolog +pkgver=7.2.3 +pkgrel=2 +pkgdesc='Prolog environment' +arch=('x86_64' 'i686') +url='http://www.swi-prolog.org/' +license=('GPL' 'LGPL') +depends=('gmp' 'readline' 'openssl' 'libarchive') +makedepends=('libxft' 'libjpeg' 'unixodbc' 'libxpm' 'libxinerama') +optdepends=('unixodbc: for using the odbc4pl library' + 'libjpeg: for using the pl2xpce library' + 'libxpm: for using the pl2xpce library' + 'libxinerama: for using the pl2xpce library' + 'libxft: for using the pl2xpce library') +source=("http://www.swi-prolog.org/download/stable/src/swipl-$pkgver.tar.gz") +sha256sums=('43657d51b7c5887bc2d2bced50a9822b86a08a6841399b8e76ee877f51d646b5') + +prepare() { + cd "swipl-$pkgver" + if [[ $CARCH == "aarch64" ]]; then + CPPFLAGS+=" -fPIC" + sed -i '/^CFLAGS/ s/$/ -fPIC/' packages/clib/maildrop/rfc822/Makefile.in packages/clib/maildrop/rfc2045/Makefile.in + fi +} + +build() { + cd "swipl-$pkgver" + ./configure --prefix=/usr --with-world + + cd src + ./configure --enable-readline --prefix=/usr + + make -C .. +} + +check() { + make -C "swipl-$pkgver" check || true +} + +package() { + make -C "swipl-$pkgver" DESTDIR="$pkgdir" install + + # Fix for FS#20873 + chmod +x "$pkgdir/usr/lib/swipl-$pkgver/library/dialect/sicstus/swipl-lfr.pl" +} + +# getver: swi-prolog.org/download/stable +# vim:set ts=2 sw=2 et: