[arch-commits] Commit in lcalc/trunk (PKGBUILD pari-2.7.patch)
Antonio Rojas
arojas at archlinux.org
Sat Jan 3 23:55:20 UTC 2015
Date: Sunday, January 4, 2015 @ 00:55:20
Author: arojas
Revision: 125266
Link to PARI
Added:
lcalc/trunk/pari-2.7.patch
Modified:
lcalc/trunk/PKGBUILD
----------------+
PKGBUILD | 18 ++++++++++++------
pari-2.7.patch | 45 +++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 57 insertions(+), 6 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2015-01-03 23:39:36 UTC (rev 125265)
+++ PKGBUILD 2015-01-03 23:55:20 UTC (rev 125266)
@@ -2,22 +2,28 @@
pkgname=lcalc
pkgver=1.23
-pkgrel=2
+pkgrel=3
pkgdesc="C++ L-function class library and command line interface"
arch=('i686' 'x86_64')
url="http://oto.math.uwaterloo.ca/~mrubinst/L_function_public/L.html"
license=('GPL2')
-depends=('gcc-libs')
+depends=('pari')
makedepends=('chrpath')
-source=("http://oto.math.uwaterloo.ca/~mrubinst/L_function_public/CODE/L-$pkgver.tar.gz" 'Lcommon.h.patch' 'gcc-4.9.patch')
+source=("http://oto.math.uwaterloo.ca/~mrubinst/L_function_public/CODE/L-$pkgver.tar.gz" 'Lcommon.h.patch' 'gcc-4.9.patch' 'pari-2.7.patch')
md5sums=('8262d4495e0bbe0283e5341ef8694c23'
'717f630a387fb1a4569e843a421f30cc'
- '436dd35b06766dffad0941bcfb511e89')
+ '436dd35b06766dffad0941bcfb511e89'
+ '5b1937955ca9ceb5d635e57af2364ed2')
prepare() {
cd L-$pkgver
- patch -p1 -i $srcdir/Lcommon.h.patch
- patch -p1 -i $srcdir/gcc-4.9.patch
+ patch -p1 -i "$srcdir"/Lcommon.h.patch
+ patch -p1 -i "$srcdir"/gcc-4.9.patch
+# port to PARI 2.7 API
+ patch -p1 -i "$srcdir"/pari-2.7.patch
+# link to PARI
+ sed -e 's|#PARI_DEFINE = -DINCLUDE_PARI|PARI_DEFINE = -DINCLUDE_PARI|' -i src/Makefile
+ sed -e 's|#include "pari.h"|#include "pari/pari.h"|' -i include/Lcommandline.h -i include/Lcommandline_elliptic.h
}
build() {
Added: pari-2.7.patch
===================================================================
--- pari-2.7.patch (rev 0)
+++ pari-2.7.patch 2015-01-03 23:55:20 UTC (rev 125266)
@@ -0,0 +1,45 @@
+Description: Port to pari 2.7 API
+Author: Luca Falavigna <dktrkranz at debian.org>
+ Tobias Hansen <thansen at debian.org>
+Bug-Debian: http://bugs.debian.org/635506
+ http://bugs.debian.org/743327
+
+--- a/src/Lcommandline.cc
++++ b/src/Lcommandline.cc
+@@ -473,7 +473,7 @@
+
+ #ifdef INCLUDE_PARI
+ if(do_elliptic_curve){
+- allocatemoremem((int) N_terms*16+1000000); //XXXXXXXXX this should depend on whether we're double or long double or mpfr double
++ allocatemem((int) N_terms*16+1000000); //XXXXXXXXX this should depend on whether we're double or long double or mpfr double
+ if (my_verbose>0) cout << "Will precompute " << N_terms << " elliptic L-function dirichlet coefficients..." << endl;
+ initialize_new_L(a1,a2,a3,a4,a6,N_terms);
+ }
+--- a/src/Lcommandline_elliptic.cc
++++ b/src/Lcommandline_elliptic.cc
+@@ -121,11 +121,11 @@
+
+
+ F = cgetg(6, t_VEC);
+- F[1] = lgeti(BIGDEFAULTPREC);
+- F[2] = lgeti(BIGDEFAULTPREC);
+- F[3] = lgeti(BIGDEFAULTPREC);
+- F[4] = lgeti(BIGDEFAULTPREC);
+- F[5] = lgeti(BIGDEFAULTPREC);
++ F[1] = (long)cgeti(BIGDEFAULTPREC);
++ F[2] = (long)cgeti(BIGDEFAULTPREC);
++ F[3] = (long)cgeti(BIGDEFAULTPREC);
++ F[4] = (long)cgeti(BIGDEFAULTPREC);
++ F[5] = (long)cgeti(BIGDEFAULTPREC);
+
+ //gaffsg(a1,(GEN) F[1]);
+ //gaffsg(a2,(GEN) F[2]);
+@@ -139,7 +139,7 @@
+ gaffect(strtoGEN(a4), (GEN) F[4]);
+ gaffect(strtoGEN(a6), (GEN) F[5]);
+
+- E = initell(F,BIGDEFAULTPREC);
++ E = ellinit(F, NULL, BIGDEFAULTPREC);
+
+ C=globalreduction(E);
+
More information about the arch-commits
mailing list