summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorWorMzy Tykashi2016-03-24 14:29:55 +0000
committerWorMzy Tykashi2016-03-24 15:40:00 +0000
commit22f35671f5c6ad9bc30d28a11c2ec3e3f1f23dc3 (patch)
tree7127d698c44725a70566210f18d4a4389e5c0166
downloadaur-22f35671f5c6ad9bc30d28a11c2ec3e3f1f23dc3.tar.gz
initial commit
-rw-r--r--.SRCINFO17
-rw-r--r--PKGBUILD32
-rw-r--r--libmatheval.install20
-rw-r--r--removeifndefs.patch30
4 files changed, 99 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..7bde85a49d04
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,17 @@
+pkgbase = libmatheval
+ pkgdesc = A C/Fortran library to parse and evaluate symbolic expressions input as text.
+ pkgver = 1.1.11
+ pkgrel = 1
+ url = https://www.gnu.org/software/libmatheval/
+ install = libmatheval.install
+ arch = i686
+ arch = x86_64
+ license = GPL3
+ depends = flex
+ source = http://ftp.gnu.org/gnu/libmatheval/libmatheval-1.1.11.tar.gz
+ source = removeifndefs.patch
+ md5sums = 595420ea60f6ddd75623847f46ca45c4
+ md5sums = b340ca489388a8c7986654f4be8127f4
+
+pkgname = libmatheval
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..3fab9b4d5392
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: WorMzy Tykashi <wormzy.tykashi@gmail.com>
+
+pkgname=libmatheval
+pkgver=1.1.11
+pkgrel=1
+pkgdesc="A C/Fortran library to parse and evaluate symbolic expressions input as text."
+arch=('i686' 'x86_64')
+url="https://www.gnu.org/software/libmatheval/"
+license=('GPL3')
+depends=('flex')
+install=libmatheval.install
+source=("http://ftp.gnu.org/gnu/libmatheval/$pkgname-$pkgver.tar.gz"
+ "removeifndefs.patch")
+noextract=()
+md5sums=('595420ea60f6ddd75623847f46ca45c4'
+ 'b340ca489388a8c7986654f4be8127f4')
+
+prepare() {
+ cd "$pkgname-$pkgver"
+ patch -p1 -i "$srcdir/removeifndefs.patch"
+}
+
+build() {
+ cd "$pkgname-$pkgver"
+ ./configure --prefix=/usr
+ make
+}
+
+package() {
+ cd "$pkgname-$pkgver"
+ make DESTDIR="$pkgdir/" install
+}
diff --git a/libmatheval.install b/libmatheval.install
new file mode 100644
index 000000000000..a1277574cd73
--- /dev/null
+++ b/libmatheval.install
@@ -0,0 +1,20 @@
+infodir=/usr/share/info
+filelist=(libmatheval.info)
+
+post_install() {
+ [ -x usr/bin/install-info ] || return 0
+ for file in ${filelist[@]}; do
+ install-info $infodir/$file.gz $infodir/dir 2> /dev/null
+ done
+}
+
+post_upgrade() {
+ post_install $1
+}
+
+pre_remove() {
+ [ -x usr/bin/install-info ] || return 0
+ for file in ${filelist[@]}; do
+ install-info --delete $infodir/$file.gz $infodir/dir 2> /dev/null
+ done
+}
diff --git a/removeifndefs.patch b/removeifndefs.patch
new file mode 100644
index 000000000000..418a3bb06e6f
--- /dev/null
+++ b/removeifndefs.patch
@@ -0,0 +1,30 @@
+diff -aur a/tests/matheval.c b/tests/matheval.c
+--- a/tests/matheval.c 2016-03-24 13:55:00.163074189 +0000
++++ b/tests/matheval.c 2016-03-24 13:52:59.492996682 +0000
+@@ -26,26 +26,6 @@
+ #include <matheval.h>
+ #include "config.h"
+
+-#ifndef HAVE_SCM_T_BITS
+-typedef long scm_t_bits;
+-#endif
+-
+-#ifndef HAVE_SCM_NUM2DBL
+-#ifdef SCM_NUM2DBL
+-#define scm_num2dbl(x,s) SCM_NUM2DBL(x)
+-#else
+-#error Neither scm_num2dbl() nor SCM_NUM2DBL available
+-#endif
+-#endif
+-
+-#ifndef HAVE_SCM_C_DEFINE_GSUBR
+-#ifdef HAVE_SCM_MAKE_GSUBR
+-#define scm_c_define_gsubr scm_make_gsubr
+-#else
+-#error Neither scm_c_define_gsubr() nor scm_make_gsubr() available
+-#endif
+-#endif
+-
+ static scm_t_bits evaluator_tag; /* Unique identifier for Guile
+ * objects of evaluator type. */
+