summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKent Fredric <kentnl@gentoo.org>2017-06-11 14:19:58 +1200
committerKent Fredric <kentnl@gentoo.org>2017-06-11 14:24:28 +1200
commit03084b60c9374c660c04d591be5ffe008516a39a (patch)
tree245509198d34be0457810dd76edabcdc92b33019
parentmedia-libs/mesa: Version bump to 17.1.2 (diff)
downloadgentoo-03084b60c9374c660c04d591be5ffe008516a39a.tar.gz
gentoo-03084b60c9374c660c04d591be5ffe008516a39a.tar.bz2
gentoo-03084b60c9374c660c04d591be5ffe008516a39a.zip
dev-perl/Math-Pari: Bump to 2.10.809.0 re bug #613624
- EAPI6 - Patched to not break when perl compiled with -flto - Patched for '.' in @INC ( Bug #613624 ) both in Math-Pari tests and upstream copy of pari Upstream: - Fixes for unescaped { on Perl 5.24+ - Fix for child targets under EUMM - Fixes for building on Solaris Bug: https://bugs.gentoo.org/613624 Package-Manager: Portage-2.3.6, Repoman-2.3.2
-rw-r--r--dev-perl/Math-Pari/Manifest1
-rw-r--r--dev-perl/Math-Pari/Math-Pari-2.10.809.0.ebuild69
-rw-r--r--dev-perl/Math-Pari/files/Math-Pari-2.10.809.0-no-dot-inc.patch31
-rw-r--r--dev-perl/Math-Pari/files/no-flto.patch74
-rw-r--r--dev-perl/Math-Pari/files/pari-2.3.5-no-dot-inc.patch61
5 files changed, 236 insertions, 0 deletions
diff --git a/dev-perl/Math-Pari/Manifest b/dev-perl/Math-Pari/Manifest
index a9ad7a1aae86..af6d679a9067 100644
--- a/dev-perl/Math-Pari/Manifest
+++ b/dev-perl/Math-Pari/Manifest
@@ -1,3 +1,4 @@
DIST Math-Pari-2.01080605.tar.gz 122627 SHA256 eed553dc838973566c23b77cc30c9130802ba502e6a33969e25183bc5831ca46 SHA512 a92ff01afce8d52c5d7c4fec1a5759b5d7b786c8f359348ac8f4e7fc95be9338b990879d4d89598dc5333f79c53a92e54f6756d0e6c9a0e9e72a4dfd15b0b263 WHIRLPOOL 7e8ecc1329750019a65819af07fe3170af511a90fcae17464163bac4654d475048ad423b1f37f06d4e11e5ff1a7b803c9fe4e298ba1b39a46700efb3609385d6
DIST Math-Pari-2.010808.zip 153838 SHA256 543633b2984a71e8adee2a6130f740cc1e22aefb95ca3e886338aee9e1ae3c06 SHA512 006e77328f0d8e61b89addbb6b8b8a8adb8c8c1591a1d3cdf80f5183a5fb30bb19219cbfc2624d15ffcdb6b0dc5cff4d69e6e27eb7cb6c29796bbab36ecfda88 WHIRLPOOL ad325762b7568548f72ffe30c20544254f3eceed8ca61e6a1938d89612798ac7a9231bc507a458760a55ba96684421530d5e2922479cc1b33359757cd8ada998
+DIST Math-Pari-2.01080900.zip 166396 SHA256 5845d9350fe0cd9d909d71b6d6b88ab67d17da88f4b0df6570938583d6f365fc SHA512 844324472632081e16d8c70e2f3b14a04cc125dc65ac1e4e75b495f7b83393cadc637c6b81d2e6657380b153a6d91eba4a437087481ffbd4c6c58c5da0e4d05b WHIRLPOOL 89fbb7e774cc7e94335f588b1a2045bda257204424fbd16186f8e4bccbf3ce52e0e43ef397b698776d369adfc883d71b4c07f7f72ff4ec0b1c1dafda9a6c6742
DIST pari-2.3.5.tar.gz 2018097 SHA256 47ddae1af73b4476660d2a89338483949067a97ffb8758c82e8189dfa4c89d88 SHA512 0e49e6310b4c76ef3370786a13aa8cbc5bb0b7dc84ec1665866d623e6284f45db8584eea759e8b5954dc9b5c8a3e866e77a377d18073ed33f11708a7e88a4cca WHIRLPOOL 1d7f3fcfb5c4b44479ea7494536bcb7c971df721a23bca9f7bdee878cc91c5beec5353920d352142534e89bb0158bfd8ad9a431a22c90fc577676e3f8ceb8b9b
diff --git a/dev-perl/Math-Pari/Math-Pari-2.10.809.0.ebuild b/dev-perl/Math-Pari/Math-Pari-2.10.809.0.ebuild
new file mode 100644
index 000000000000..7317bc15711e
--- /dev/null
+++ b/dev-perl/Math-Pari/Math-Pari-2.10.809.0.ebuild
@@ -0,0 +1,69 @@
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+
+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"
+
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~mips ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
+IUSE=""
+
+# 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
+RDEPEND="~sci-mathematics/pari-${PARI_VER}"
+DEPEND="${RDEPEND}
+ app-arch/unzip
+"
+
+S_PARI=${WORKDIR}/pari-${PARI_VER}
+
+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/
+ 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}"
+ [ -f "$i" -a ! -f "$o32" ] && cp -al "$i" "$o32"
+ [ -f "$i" -a ! -f "$o64" ] && cp -al "$i" "$o64"
+ done
+ cd "${S_PARI}"
+ eapply "${FILESDIR}/pari-${PARI_VER}-no-dot-inc.patch"
+ cd "${S}"
+ 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}"
+}
diff --git a/dev-perl/Math-Pari/files/Math-Pari-2.10.809.0-no-dot-inc.patch b/dev-perl/Math-Pari/files/Math-Pari-2.10.809.0-no-dot-inc.patch
new file mode 100644
index 000000000000..95ebcf9d18f0
--- /dev/null
+++ b/dev-perl/Math-Pari/files/Math-Pari-2.10.809.0-no-dot-inc.patch
@@ -0,0 +1,31 @@
+From 712cff175abfbf95428ed09a875a15f4047ce105 Mon Sep 17 00:00:00 2001
+From: Kent Fredric <kentfredric@gmail.com>
+Date: Sun, 11 Jun 2017 13:22:46 +1200
+Subject: [PATCH] Fix "do" to forcibly use a relative path on Perl 5.26
+
+Reliance on "." in @INC was previously how this worked. But that
+becomes broken on Perl 5.26
+
+Resolves RT#120711 ( Well, at least the Math-Pari parts, the pari
+ parts themselves need additional fixing, and that's not viable
+ to really perform in Math::Pari )
+
+Bug: https://rt.cpan.org/Ticket/Display.html?id=120711
+---
+ test_eng/ex.t | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/test_eng/ex.t b/test_eng/ex.t
+index a1a2286..0ad57ee 100644
+--- a/test_eng/ex.t
++++ b/test_eng/ex.t
+@@ -10,5 +10,5 @@ $dir1 = "CHANGE_ME";
+ $dir1 = "$dir/../$dir1" unless $dir1 =~ m|^([a-z]:)?[\\/]|i;
+ @ARGV = "$dir1/src/test/$long_bits/$name";
+ @ARGV = "$dir1/src/test/32/$name" unless -r $ARGV[0];
+-do 'test_eng/Testout.pm';
++do './test_eng/Testout.pm';
+ die if $@;
+--
+2.13.1
+
diff --git a/dev-perl/Math-Pari/files/no-flto.patch b/dev-perl/Math-Pari/files/no-flto.patch
new file mode 100644
index 000000000000..d3902ac5d470
--- /dev/null
+++ b/dev-perl/Math-Pari/files/no-flto.patch
@@ -0,0 +1,74 @@
+From c169041dfa888ec3815aa5bacc97bcc0f21dc318 Mon Sep 17 00:00:00 2001
+From: Kent Fredric <kentfredric@gmail.com>
+Date: Sun, 11 Jun 2017 13:05:59 +1200
+Subject: [PATCH] Disable -flto as it breaks compile.
+
+LTO seems to be bad for static/shared libraries or something.
+
+Turning it off until somebody works out how to make it not cause
+a compile failure, on top of all the crap Pari does.
+---
+ Makefile.PL | 17 ++++++++++++-----
+ 1 file changed, 12 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile.PL b/Makefile.PL
+index f3025bd..c32eb6a 100644
+--- a/Makefile.PL
++++ b/Makefile.PL
+@@ -42,18 +42,23 @@ Could not find GP/PARI build directory, please run Makefile.PL
+ with paridir=/directory option.
+ EOD
+
++my $optimize = $Config{optimize};
++my $ldflags = $Config{ldflags};
++
++s/(^|\s)-flto(\s|$)/$1$2/ for $optimize, $ldflags;
++
+ my $gcc_version
+ = defined($Config{gccversion}) ? ", gccversion=$Config{gccversion}" : "";
+ print <<EOP;
+ Setting up Math::Pari with Perl $] on $^O version $Config{osvers};
+ cc=$Config{cc}$gcc_version, cccdlflags='$Config{cccdlflags}',
+ ccflags='$Config{ccflags}',
+- optimize='$Config{optimize}',
+- ld=$Config{ld}, ldflags='$Config{ldflags}'.
++ optimize='$optimize',
++ ld=$Config{ld}, ldflags='$ldflags'.
+ EOP
+
+ if ($^O eq 'solaris' and $Config{cc} eq 'gcc'
+- and ( $Config{optimize} =~ s/(?<!\S)(-xarch=386|-xildoff)(?!\S)//g
++ and ( $optimize =~ s/(?<!\S)(-xarch=386|-xildoff)(?!\S)//g
+ or $Config{cccdlflags} =~ s/(?<!\S)-KPIC(?!\S)/-fPIC/ )) {
+ # Vendor's Perl has major problems with building extensions; try to fix this
+ # One way is to use perlgcc; but it does not work with 5.8.4
+@@ -61,7 +66,7 @@ if ($^O eq 'solaris' and $Config{cc} eq 'gcc'
+ print <<EOP;
+
+ ... Broken config of gcc-on-Solaris detected! I would try to work around this.
+-... Reset: cccdlflags --> '$Config{cccdlflags}', optimize -> '$Config{optimize}'.
++... Reset: cccdlflags --> '$Config{cccdlflags}', optimize -> '$optimize'.
+
+ EOP
+ }
+@@ -181,7 +186,7 @@ $define .= ' -DLONG_SHORTER_THAN_IV' if $perl_int_size > $longsize;
+
+ $define .= ' -Derr=pari_err'; # On linux it can get a wrong dynamic loading
+ $define .= ' -DHAVE_LADD' if $opts{have_ladd};
+-$define .= ' -DGCC_INLINE' if $Config{gccversion} and not $Config{optimize} =~ /-g\b/;
++$define .= ' -DGCC_INLINE' if $Config{gccversion} and not $optimize =~ /-g\b/;
+ $define .= ' -DHAVE_PARIPRIV' if -f "$paridir/src/headers/paripriv.h";
+ #$define .= ' -DNO_GRAPHICS_PARI' unless -f "$paridir/src/graph/plotgnuplot.c";
+
+@@ -200,6 +205,8 @@ my $extra_inc = extra_includes($paridir);
+ &WriteMakefile(
+ LIBS => $libs,
+ INC => $extra_inc . ' -I $(PARI_DIR)/src/headers -I $(PARI_DIR)/src -I ./libPARI',
++ OPTIMIZE => $optimize,
++ LDFLAGS => $ldflags,
+ NAME => 'Math::Pari',
+ ($common::parilib ? () :
+ (MYEXTLIB => 'libPARI/libPARI$(LIB_EXT)')),
+--
+2.13.1
+
diff --git a/dev-perl/Math-Pari/files/pari-2.3.5-no-dot-inc.patch b/dev-perl/Math-Pari/files/pari-2.3.5-no-dot-inc.patch
new file mode 100644
index 000000000000..cd34851a30fb
--- /dev/null
+++ b/dev-perl/Math-Pari/files/pari-2.3.5-no-dot-inc.patch
@@ -0,0 +1,61 @@
+From 4f1e00df5ea1e51042146f6277bb1af02f249cc3 Mon Sep 17 00:00:00 2001
+From: Kent Fredric <kentfredric@gmail.com>
+Date: Sun, 11 Jun 2017 10:31:03 +1200
+Subject: [PATCH] Fix for 5.26 removal of '.' in @INC
+
+Previous scripts assumed CWD was in @INC and that "PARI::822" was in
+wherever CWD was.
+
+This fixes both of those, and the latter, because its not obvious
+from the build system where one should assume CWD to be.
+
+Instead, the absolute path of the directory of these scripts is
+inserted into @INC
+---
+ src/desc/gen_member | 4 ++++
+ src/desc/gen_proto | 4 ++++
+ src/desc/merge_822 | 4 ++++
+ 3 files changed, 12 insertions(+)
+
+diff --git a/src/desc/gen_member b/src/desc/gen_member
+index 2f3cf52..66dea2b 100755
+--- a/src/desc/gen_member
++++ b/src/desc/gen_member
+@@ -1,4 +1,8 @@
+ #!/usr/bin/perl -w
++use File::Spec;
++use File::Basename qw( dirname );
++use lib dirname(File::Spec->rel2abs(__FILE__));
++
+ use PARI::822;
+
+ $class='member_functions';
+diff --git a/src/desc/gen_proto b/src/desc/gen_proto
+index 1b507fa..2fb4d3f 100755
+--- a/src/desc/gen_proto
++++ b/src/desc/gen_proto
+@@ -1,4 +1,8 @@
+ #!/usr/bin/perl -w
++use File::Spec;
++use File::Basename qw( dirname );
++use lib dirname(File::Spec->rel2abs(__FILE__));
++
+ use PARI::822;
+
+ $class=$ARGV[0];
+diff --git a/src/desc/merge_822 b/src/desc/merge_822
+index a02d612..9ca8252 100755
+--- a/src/desc/merge_822
++++ b/src/desc/merge_822
+@@ -1,4 +1,8 @@
+ #!/usr/bin/perl -w
++use File::Spec;
++use File::Basename qw( dirname );
++use lib dirname(File::Spec->rel2abs(__FILE__));
++
+ use PARI::822;
+
+ PARI::822::read(\%funcs,$_,1)
+--
+2.13.1
+