summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorwangjiezhe2015-12-21 17:02:42 +0800
committerwangjiezhe2015-12-21 17:02:42 +0800
commit713f48d4e4e6ddc532d9ec58626cca12beb14f7f (patch)
tree9b3ce0d4da1ae0eca2225e3a060e0fd61bc56024
downloadaur-713f48d4e4e6ddc532d9ec58626cca12beb14f7f.tar.gz
Initial import
-rw-r--r--.SRCINFO64
-rw-r--r--.gitignore9
-rw-r--r--PKGBUILD177
-rwxr-xr-xcsl4
-rw-r--r--qreduce-file-location.patch39
-rw-r--r--qreduce.desktop8
-rwxr-xr-xredcsl4
-rw-r--r--redcsl.desktop9
-rwxr-xr-xredpsl16
-rw-r--r--reduce-addons-svn.install30
-rw-r--r--reduce-csl-svn.install11
11 files changed, 371 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 00000000000..1a9fbec2970
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,64 @@
+# Generated by mksrcinfo v8
+# Sun Dec 20 13:10:06 UTC 2015
+pkgbase = reduce-svn
+ pkgver = 20151220.3311
+ pkgrel = 1
+ url = http://reduce-algebra.sourceforge.net/
+ arch = i686
+ arch = x86_64
+ groups = science
+ license = BSD
+ makedepends = subversion
+ makedepends = texlive-htmlxml
+ makedepends = imagemagick
+ depends = ncurses
+ depends = libxext
+ depends = libxrandr
+ depends = libxft
+ depends = freetype2
+ depends = expat
+ depends = libx11
+ depends = libxcursor
+ source = reduce::svn+http://svn.code.sf.net/p/reduce-algebra/code/trunk
+ source = csl
+ source = redcsl
+ source = redpsl
+ source = redcsl.desktop
+ source = qreduce.desktop
+ source = qreduce-file-location.patch
+ sha256sums = SKIP
+ sha256sums = 5a6065ef28bc64e38cc5c7e9c3ce5145c273e3ea7e7c073d8417a4d94fa6bafe
+ sha256sums = 9724e19545f181f6456e30bc1eff837cb708678f162a939b45f23627ad50c46c
+ sha256sums = 3d383ac93cb831a5a142395e76a9c275dc7e49dc150763610869e56e5a795e65
+ sha256sums = 22c7c510fba9ec2bcb8f476af0c96055a915a31f34c01ece43ff21d0dfa9dd0d
+ sha256sums = 9dce4d401c759c933ebc3ffbe0eff86150f04829ca10a9fd6f6faba4498f47ad
+ sha256sums = e387eada63c3e15cb75f5f5a5060491831f607d93c7f97b30262fc30cf1ebea3
+
+pkgname = reduce-csl-svn
+ pkgdesc = REDUCE Computer Algebra System -- CSL version
+ install = reduce-csl-svn.install
+ depends = reduce-common
+ provides = reduce-csl
+ conflicts = reduce-csl
+ conflicts = reduce-algebra
+
+pkgname = reduce-psl-svn
+ pkgdesc = REDUCE Computer Algebra System -- PSL version
+ depends = reduce-common
+ provides = reduce-psl
+ conflicts = reduce-psl
+
+pkgname = reduce-common-svn
+ pkgdesc = REDUCE Computer Algebra System -- common files
+ provides = reduce-common
+ conflicts = reduce-common
+
+pkgname = reduce-addons-svn
+ pkgdesc = Useful addons for the REDUCE Computer Algebra System
+ install = reduce-addons-svn.install
+ optdepends = reduce-csl: REDUCE Computer Algebra System
+ optdepends = reduce-psl: REDUCE Computer Algebra System
+ optdepends = python2-pyside: for QT-based GUI
+ provides = reduce-addons
+ conflicts = reduce-addons
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000000..6865c5e8d08
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,9 @@
+# Vim
+*~
+*.swp
+
+# Makepkg
+*.pkg.tar.xz
+/pkg/
+/src/
+/reduce
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..c844b3ae313
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,177 @@
+# Maintainer: serkho <sergey.khorev@gmail.com>
+# adopted from reduce-algebra by quasi <quasi@aur.archlinux.org>
+# Contributor: wangjiezhe <wangjiezhe AT yandex DOT com>
+
+pkgbase=reduce-svn
+_pkgbase=reduce
+pkgname=(reduce-csl-svn reduce-psl-svn reduce-common-svn reduce-addons-svn)
+pkgver=20151220.3311
+pkgrel=1
+arch=('i686' 'x86_64')
+url="http://reduce-algebra.sourceforge.net/"
+license=('BSD')
+groups=('science')
+makedepends=('subversion' 'texlive-htmlxml' 'imagemagick') # for documentation
+depends=('ncurses' 'libxext' 'libxrandr' 'libxft' 'freetype2' 'expat' 'libx11' 'libxcursor')
+source=("${_pkgbase}::svn+http://svn.code.sf.net/p/reduce-algebra/code/trunk"
+ 'csl' 'redcsl' 'redpsl'
+ 'redcsl.desktop' 'qreduce.desktop'
+ 'qreduce-file-location.patch')
+sha256sums=('SKIP'
+ '5a6065ef28bc64e38cc5c7e9c3ce5145c273e3ea7e7c073d8417a4d94fa6bafe'
+ '9724e19545f181f6456e30bc1eff837cb708678f162a939b45f23627ad50c46c'
+ '3d383ac93cb831a5a142395e76a9c275dc7e49dc150763610869e56e5a795e65'
+ '22c7c510fba9ec2bcb8f476af0c96055a915a31f34c01ece43ff21d0dfa9dd0d'
+ '9dce4d401c759c933ebc3ffbe0eff86150f04829ca10a9fd6f6faba4498f47ad'
+ 'e387eada63c3e15cb75f5f5a5060491831f607d93c7f97b30262fc30cf1ebea3')
+
+pkgver() {
+ cd ${srcdir}/${_pkgbase}
+ svn info | awk '/Revision/{r=$2}/Date/{gsub(/-/,"");d=$4}END{print d"."r}'
+}
+
+prepare() {
+ rm -rf "${srcdir}/${_pkgbase}-build"
+ svn export "${srcdir}/${_pkgbase}" "${srcdir}/${_pkgbase}-build"
+ #svn export --force "${srcdir}/${_pkgbase}" "${srcdir}/${_pkgbase}-build"
+
+ cd "${srcdir}/${_pkgbase}-build"
+ patch -Np0 -i "${srcdir}/qreduce-file-location.patch"
+}
+
+build() {
+ cd "${srcdir}/${_pkgbase}-build"
+ ./configure --with-csl
+ ./configure --with-psl
+ make -j1
+ (cd generic/redfront && make -j1)
+ (cd generic/casefold && cc casefold.c -o casefold)
+ (cd generic/libreduce && make PYTHON=/usr/bin/python2 -j1)
+ (cd generic/emacs && makeinfo reduce-ide.texinfo)
+}
+
+package_reduce-csl-svn() {
+ depends=('reduce-common')
+ provides=('reduce-csl')
+ conflicts=('reduce-csl' 'reduce-algebra')
+ pkgdesc='REDUCE Computer Algebra System -- CSL version'
+ #pkgdesc="A portable general-purpose computer algebra system (CSL version)"
+ install=reduce-csl-svn.install
+
+ install -Dm755 redcsl ${pkgdir}/usr/bin/redcsl
+ install -Dm755 csl ${pkgdir}/usr/bin/csl
+ install -Dm644 redcsl.desktop ${pkgdir}/usr/share/applications/redcsl.desktop
+
+ cd "${srcdir}/${_pkgbase}-build"
+
+ install -Dm644 cslbuild/generated-c/reduce.img ${pkgdir}/usr/lib/reduce/cslbuild/csl/reduce.img
+ install -Dm644 cslbuild/generated-c/csl.img ${pkgdir}/usr/lib/reduce/cslbuild/csl/csl.img
+
+ install -d ${pkgdir}/usr/lib/reduce/cslbuild/csl
+ install -d ${pkgdir}/usr/share/reduce/
+
+ install -t ${pkgdir}/usr/lib/reduce/cslbuild/csl/ cslbuild/${CARCH}-unknown-linux-gnu/csl/{csl,reduce}
+
+ cp -r cslbuild/${CARCH}-unknown-linux-gnu/csl/reduce.resources ${pkgdir}/usr/lib/reduce/cslbuild/csl/
+ cp -r cslbuild/${CARCH}-unknown-linux-gnu/csl/reduce.fonts ${pkgdir}/usr/share/reduce/fonts
+
+ install -Dm644 debianbuild/reduce/debian/copyright ${pkgdir}/usr/share/doc/reduce-csl/copyright
+ install -Dm644 debianbuild/reduce/debian/redcsl.1 ${pkgdir}/usr/share/man/man1/redcsl.1
+
+ cd "${pkgdir}/usr/lib/reduce/cslbuild/csl"
+ ln -s ../../../../share/reduce/fonts reduce.fonts
+
+ cd "${pkgdir}/usr/share/reduce"
+ ln -s ../../lib/reduce/cslbuild
+}
+
+package_reduce-psl-svn() {
+ depends=('reduce-common')
+ provides=('reduce-psl')
+ conflicts=('reduce-psl')
+ pkgdesc='REDUCE Computer Algebra System -- PSL version'
+
+ install -D redpsl ${pkgdir}/usr/bin/redpsl
+
+ cd "${srcdir}/${_pkgbase}-build"
+
+ install -d ${pkgdir}/usr/lib/reduce/pslbuild
+ install -d ${pkgdir}/usr/share/reduce
+
+ cp -r pslbuild/${CARCH}-unknown-linux-gnu/{psl,red} ${pkgdir}/usr/lib/reduce/pslbuild/
+
+ install -Dm644 debianbuild/reduce/debian/copyright ${pkgdir}/usr/share/doc/reduce-psl/copyright
+ install -Dm644 debianbuild/reduce/debian/redpsl.1 ${pkgdir}/usr/share/man/man1/redpsl.1
+
+ cd "${pkgdir}/usr/share/reduce"
+ ln -s ../../lib/reduce/pslbuild
+}
+
+package_reduce-common-svn() {
+ provides=('reduce-common')
+ conflicts=('reduce-common')
+ pkgdesc='REDUCE Computer Algebra System -- common files'
+
+ cd "${srcdir}/${_pkgbase}-build"
+
+ install -d ${pkgdir}/usr/share/reduce/doc
+
+ cp -r packages ${pkgdir}/usr/share/reduce/
+
+ install -Dm644 debianbuild/reduce/debian/copyright ${pkgdir}/usr/share/doc/reduce-common/copyright
+
+ cp -r doc/{manual,manual2,misc,primers,util} ${pkgdir}/usr/share/reduce/doc
+
+ install -Dm644 generic/qreduce/Bumblebee.png ${pkgdir}/usr/share/icons/redcsl.png
+}
+
+package_reduce-addons-svn() {
+ provides=('reduce-addons')
+ conflicts=('reduce-addons')
+ pkgdesc='Useful addons for the REDUCE Computer Algebra System'
+ optdepends=(
+ 'reduce-csl: REDUCE Computer Algebra System'
+ 'reduce-psl: REDUCE Computer Algebra System'
+ 'python2-pyside: for QT-based GUI'
+ )
+ install=reduce-addons-svn.install
+
+ cd "${srcdir}/${_pkgbase}-build"
+
+ install -d ${pkgdir}/usr/lib/reduce
+ install -d ${pkgdir}/usr/share/doc/reduce-addons
+ install -d ${pkgdir}/usr/share/emacs/site-lisp/reduce
+
+ install -D generic/redfront/${CARCH}-unknown-linux-gnu/redfront/redfront ${pkgdir}/usr/bin/redfront
+ install -Dm644 generic/redfront/src/redfront.1 ${pkgdir}/usr/share/man/man1/redfront.1
+
+ install -D generic/breduce/breduce ${pkgdir}/usr/bin/breduce
+ install -Dm644 generic/breduce/breduce.1 ${pkgdir}/usr/share/man/man1/breduce.1
+ install -t ${pkgdir}/usr/share/doc/reduce-addons generic/breduce/breduce.{bbl,pdf,tex}
+
+ install -D generic/casefold/casefold ${pkgdir}/usr/bin/casefold
+ install -Dm644 generic/casefold/README ${pkgdir}/usr/share/doc/reduce-addons/README.casefold
+
+ install -t ${pkgdir}/usr/lib/reduce generic/libreduce/${CARCH}-unknown-linux-gnu/{libreduce.so,RedPy.so}
+
+ cp -r generic/qreduce ${pkgdir}/usr/share/
+
+ install -t ${pkgdir}/usr/share/emacs/site-lisp/reduce generic/emacs/reduce-{mode,run}.el
+ install -Dm644 generic/emacs/reduce-ide.texinfo ${pkgdir}/usr/share/doc/reduce-addons/reduce-ide.texinfo
+ install -Dm644 generic/emacs/README ${pkgdir}/usr/share/doc/reduce-addons/README.emacs
+ install -Dm644 generic/emacs/reduce-ide.info ${pkgdir}/usr/share/info/reduce-ide.info
+
+ cd "${pkgdir}/usr/bin"
+ ln -s redfront rfcsl
+ ln -s redfront rfpsl
+ ln -s ../share/qreduce/qreduce.py qreduce
+
+ cd "${pkgdir}/usr/share/man/man1"
+ ln -s redfront.1 rfcsl.1
+ ln -s redfront.1 rfpsl.1
+
+ cd "${pkgdir}/usr/share/qreduce"
+ ln -s ../../lib/reduce/RedPy.so
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/csl b/csl
new file mode 100755
index 00000000000..b3644551be8
--- /dev/null
+++ b/csl
@@ -0,0 +1,4 @@
+#! /bin/sh
+
+exec /usr/lib/reduce/cslbuild/csl/csl $*
+
diff --git a/qreduce-file-location.patch b/qreduce-file-location.patch
new file mode 100644
index 00000000000..9bd84b1c209
--- /dev/null
+++ b/qreduce-file-location.patch
@@ -0,0 +1,39 @@
+diff -ur generic.orig/libreduce/Makefile generic/libreduce/Makefile
+--- generic.orig/libreduce/Makefile 2015-12-19 20:41:15.750461410 +0800
++++ generic/libreduce/Makefile 2015-12-19 20:41:21.805483683 +0800
+@@ -21,7 +21,7 @@
+ autoheader
+ mkdir -p $(BUILD); \
+ cd $(BUILD); \
+- ../src/configure --disable-universal; \
++ ../src/configure --disable-universal --disable-logfile; \
+ make
+
+ clean:
+diff -ur generic.orig/qreduce/qreduce.py generic/qreduce/qreduce.py
+--- generic.orig/qreduce/qreduce.py 2015-12-19 20:41:15.750461410 +0800
++++ generic/qreduce/qreduce.py 2015-12-19 20:41:21.806483686 +0800
+@@ -1,4 +1,4 @@
+-#!/usr/bin/env python
++#!/usr/bin/env python2
+ # ----------------------------------------------------------------------
+ # $Id: qreduce.py 2640 2014-08-12 02:04:01Z thomas-sturm $
+ # ----------------------------------------------------------------------
+diff -ur generic.orig/qreduce/qrmodel.py generic/qreduce/qrmodel.py
+--- generic.orig/qreduce/qrmodel.py 2015-12-19 20:41:15.750461410 +0800
++++ generic/qreduce/qrmodel.py 2015-12-19 21:01:22.187907281 +0800
+@@ -59,13 +59,6 @@
+
+ from subprocess import Popen, PIPE
+
+-here = os.path.dirname(os.path.realpath(__file__))
+-p = Popen("%s/../../config.guess" % here, stdout=PIPE, stderr=PIPE)
+-config_guess, err = p.communicate()
+-p = Popen(["%s/../../scripts/findhost.sh" % here, config_guess], stdout=PIPE, stderr=PIPE)
+-arch, err = p.communicate()
+-sys.path.append("%s/../libreduce/%s" % (here, arch.rstrip()))
+-
+ from RedPy import procNew, procDelete, ansNew, ansDelete
+
+
+Only in generic/qreduce: .ropeproject
diff --git a/qreduce.desktop b/qreduce.desktop
new file mode 100644
index 00000000000..9f4a603348a
--- /dev/null
+++ b/qreduce.desktop
@@ -0,0 +1,8 @@
+[Desktop Entry]
+Name=QReduce
+Comment=Qt-based worksheet GUI for Reduce
+Icon=/usr/share/qreduce/Bumblebee.png
+Type=Application
+Categories=Education;Science;Math;
+Exec=qreduce
+Terminal=true
diff --git a/redcsl b/redcsl
new file mode 100755
index 00000000000..6ba46442a03
--- /dev/null
+++ b/redcsl
@@ -0,0 +1,4 @@
+#! /bin/sh
+
+exec /usr/lib/reduce/cslbuild/csl/reduce $*
+
diff --git a/redcsl.desktop b/redcsl.desktop
new file mode 100644
index 00000000000..2ccfb3af42f
--- /dev/null
+++ b/redcsl.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Name=Redcsl
+GenericName=Reduce Algebra System (CSL version)
+Comment=A portable general-purpose computer algebra system (CSL version)
+Icon=redcsl
+Type=Application
+Categories=Education;Science;Math;
+Exec=redcsl
+Terminal=true
diff --git a/redpsl b/redpsl
new file mode 100755
index 00000000000..0589336486c
--- /dev/null
+++ b/redpsl
@@ -0,0 +1,16 @@
+#! /bin/sh
+
+case `uname -m` in
+i*)
+ STORE=16000000
+ ;;
+x86_64)
+ STORE=1000
+ ;;
+esac
+
+bin="/usr/lib/reduce/pslbuild/psl/bpsl"
+img="/usr/lib/reduce/pslbuild/red/reduce.img"
+
+exec $bin -td $STORE -f $img $*
+
diff --git a/reduce-addons-svn.install b/reduce-addons-svn.install
new file mode 100644
index 00000000000..544f71b9bee
--- /dev/null
+++ b/reduce-addons-svn.install
@@ -0,0 +1,30 @@
+infodir=/usr/share/info
+filelist=(reduce-ide.info)
+
+post_install() {
+ update-desktop-database -q
+ for file in "${filelist[@]}"; do
+ install-info "$infodir/$file.gz" "$infodir/dir" 2> /dev/null
+ done
+ while read; do printf '%s\n' "$REPLY"; done <<- EOF
+ Warning! This package requires the REDUCE Computer Algebra System
+ that is available in one of the packages in the optdepends array!
+ It will not work without one of those!
+EOF
+}
+
+post_upgrade() {
+ update-desktop-database -q
+ for file in "${filelist[@]}"; do
+ install-info "$infodir/$file.gz" "$infodir/dir" 2> /dev/null
+ done
+}
+
+pre_remove() {
+ update-desktop-database -q
+ for file in "${filelist[@]}"; do
+ install-info --delete "$infodir/$file.gz" "$infodir/dir" 2> /dev/null
+ done
+}
+
+# vim:set ts=2 sw=2 et:
diff --git a/reduce-csl-svn.install b/reduce-csl-svn.install
new file mode 100644
index 00000000000..e111ef94605
--- /dev/null
+++ b/reduce-csl-svn.install
@@ -0,0 +1,11 @@
+post_install() {
+ update-desktop-database -q
+}
+
+post_upgrade() {
+ post_install
+}
+
+post_remove() {
+ post_install
+}