summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2022-07-02 15:31:58 +0000
committerSam James <sam@gentoo.org>2022-07-02 15:32:11 +0000
commitda4fe8ad61e23434294d1846e83a687a650a84db (patch)
tree674d06eaa2eceb73e1ed62a99a883fe194ce075a /dev-perl/Math-Pari
parentdev-perl/HTML-Mason: update EAPI 6 -> 7 (diff)
downloadgentoo-da4fe8ad61e23434294d1846e83a687a650a84db.tar.gz
gentoo-da4fe8ad61e23434294d1846e83a687a650a84db.tar.bz2
gentoo-da4fe8ad61e23434294d1846e83a687a650a84db.zip
dev-perl/Math-Pari: update EAPI 6 -> 8
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-perl/Math-Pari')
-rw-r--r--dev-perl/Math-Pari/Math-Pari-2.10.809.0-r2.ebuild75
1 files changed, 75 insertions, 0 deletions
diff --git a/dev-perl/Math-Pari/Math-Pari-2.10.809.0-r2.ebuild b/dev-perl/Math-Pari/Math-Pari-2.10.809.0-r2.ebuild
new file mode 100644
index 000000000000..c4edab03ae9e
--- /dev/null
+++ b/dev-perl/Math-Pari/Math-Pari-2.10.809.0-r2.ebuild
@@ -0,0 +1,75 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DIST_AUTHOR=ILYAZ
+DIST_SECTION=modules
+DIST_VERSION=2.01080900
+DIST_A_EXT=zip
+inherit perl-module toolchain-funcs
+
+PARI_VER=2.3.5
+
+DESCRIPTION="Perl interface to PARI"
+SRC_URI="${SRC_URI}
+ http://pari.math.u-bordeaux.fr/pub/pari/unix/pari-${PARI_VER}.tar.gz"
+S_PARI="${WORKDIR}"/pari-${PARI_VER}
+
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-solaris"
+
+# Math::Pari requires that a copy of the pari source in a parallel
+# directory to where you build it. It does not need to compile it, but
+# it does need to be the same version as is installed, hence the hard
+# DEPEND below
+BDEPEND="app-arch/unzip"
+
+PATCHES=(
+ "${FILESDIR}/no-flto.patch"
+ "${FILESDIR}/${P}-no-dot-inc.patch"
+)
+
+src_prepare() {
+ # On 64-bit hardware, these files are needed in both the 64/ and 32/
+ # directories for the testsuite to pass.
+ cd "${S_PARI}"/src/test/ || die
+
+ local t
+ for t in analyz compat ellglobalred elliptic galois graph intnum kernel \
+ linear nfields number objets ploth polyser program qfbsolve rfrac \
+ round4 stark sumiter trans ; do
+ i="in/${t}"
+ o32="32/${t}"
+ o64="64/${t}"
+
+ if [[ -f "${i}" && ! -f "${o32}" ]] ; then
+ cp -al "${i}" "${o32}" || die
+ fi
+
+ if [[ -f "$i" && ! -f "$o64" ]] ; then
+ cp -al "${i}" "${o64}" || die
+ fi
+ done
+
+ cd "${S_PARI}" || die
+ eapply "${FILESDIR}/pari-${PARI_VER}-no-dot-inc.patch"
+ cd "${S}" || die
+
+ perl-module_src_prepare
+}
+
+src_configure() {
+ # Unfortunately the assembly routines math-pari has for SPARC do not appear
+ # to be working at current. Perl cannot test math-pari or anything that
+ # pulls in the math-pari module as DynaLoader cannot load the resulting
+ # .so files math-pari generates. As such, we have to use the generic
+ # non-machine specific assembly methods here.
+ use sparc && myconf="${myconf} machine=none"
+
+ perl-module_src_configure
+}
+
+src_compile() {
+ emake AR="$(tc-getAR)" OTHERLDFLAGS="${LDFLAGS}"
+}