pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/math/p5-Math-Pari math/p5-Math-Pari: Update to 2.03052...
details: https://anonhg.NetBSD.org/pkgsrc/rev/f00ae97d7d6a
branches: trunk
changeset: 382636:f00ae97d7d6a
user: ast <ast%pkgsrc.org@localhost>
date: Tue Aug 02 07:22:00 2022 +0000
description:
math/p5-Math-Pari: Update to 2.030523 (from 2.01080900)
Way too many changes since 2.01080900 to re-mention here, for details
see https://metacpan.org/release/ILYAZ/Math-Pari-2.030523/changes
That said, a lot of work seems to have been into the modules own
patch handling and fixing/adding tests. In fact, for 2.030523 we
have now:
All tests PASS:
Files=7, Tests=591
Up from
Files=5, Tests=564
for 2.01080900 albeit with the exact same five Binary and
Hexadecimal "non-portable number" warnings in test t/00_Pari.t
By skipping GNUPlot and Math::PariBuild by re-using the earlier
Makefile.PL we can avoid a lot of the apparent grief the build
would otherwise encounter.
diffstat:
math/p5-Math-Pari/Makefile | 11 +-
math/p5-Math-Pari/distinfo | 11 +-
math/p5-Math-Pari/patches/patch-Makefile.PL | 400 ++++++++++++++++++++++++++++
math/p5-Math-Pari/patches/patch-aa | 275 -------------------
math/p5-Math-Pari/patches/patch-ab | 23 -
5 files changed, 410 insertions(+), 310 deletions(-)
diffs (truncated from 761 to 300 lines):
diff -r 0efc33c19e36 -r f00ae97d7d6a math/p5-Math-Pari/Makefile
--- a/math/p5-Math-Pari/Makefile Tue Aug 02 06:00:13 2022 +0000
+++ b/math/p5-Math-Pari/Makefile Tue Aug 02 07:22:00 2022 +0000
@@ -1,11 +1,9 @@
-# $NetBSD: Makefile,v 1.58 2022/06/28 11:34:40 wiz Exp $
+# $NetBSD: Makefile,v 1.59 2022/08/02 07:22:00 ast Exp $
-DISTNAME= Math-Pari-2.01080900
-PKGNAME= p5-${DISTNAME:S/900/9.00/}
-PKGREVISION= 7
+DISTNAME= Math-Pari-2.030523
+PKGREVISION= 1
CATEGORIES+= perl5
MASTER_SITES= ${MASTER_SITE_PERL_CPAN:=Math/}
-EXTRACT_SUFX= .zip
MAINTAINER= pkgsrc-users%NetBSD.org@localhost
HOMEPAGE= https://metacpan.org/release/Math-Pari
@@ -21,6 +19,7 @@
#MAKE_ENV+= MP_NOGNUPLOT=1
MAKE_PARAMS+= pariprefix=${PREFIX:Q}
PERL5_PACKLIST= auto/Math/Pari/.packlist
+CFLAGS.NetBSD+= -DUSE_STANDALONE_PARILIB=1
post-extract:
${RM} ${WRKSRC}/libPARI/Makefile.PL
@@ -28,7 +27,7 @@
BUILDLINK_API_DEPENDS.pari+= pari>=2.3.5nb1<2.4
.include "../../math/pari23/buildlink3.mk"
MAKE_PARAMS+= libpari=${PARI_LIB}
-.if !empty(PKG_BUILD_OPTIONS.pari:Mgmp)
+.if ${PKG_BUILD_OPTIONS.pari:Mgmp}
MAKE_PARAMS+= addlibs="-lgmp"
.endif
diff -r 0efc33c19e36 -r f00ae97d7d6a math/p5-Math-Pari/distinfo
--- a/math/p5-Math-Pari/distinfo Tue Aug 02 06:00:13 2022 +0000
+++ b/math/p5-Math-Pari/distinfo Tue Aug 02 07:22:00 2022 +0000
@@ -1,7 +1,6 @@
-$NetBSD: distinfo,v 1.25 2021/10/26 10:55:54 nia Exp $
+$NetBSD: distinfo,v 1.26 2022/08/02 07:22:00 ast Exp $
-BLAKE2s (Math-Pari-2.01080900.zip) = bce371462810fbd3a5550ae049a9a6490945015b9044ffc0359bdae076a5a9b5
-SHA512 (Math-Pari-2.01080900.zip) = 844324472632081e16d8c70e2f3b14a04cc125dc65ac1e4e75b495f7b83393cadc637c6b81d2e6657380b153a6d91eba4a437087481ffbd4c6c58c5da0e4d05b
-Size (Math-Pari-2.01080900.zip) = 166396 bytes
-SHA1 (patch-aa) = 0a03edf36a3e162ccdbc6514faec3cf2d049f893
-SHA1 (patch-ab) = 32ddc27824bbb5ac88adc0dece0f436044b8d9c7
+BLAKE2s (Math-Pari-2.030523.tar.gz) = 10653f3eb0d4f6ed32f30941ab744fee1fa77668cf5de22b54d7b3027c93693e
+SHA512 (Math-Pari-2.030523.tar.gz) = 4f75a745111eed1c326270fc4cff5f7785fd353ffbbaf21a33215974671cdb2a4ff8d397a2df41b24002312a43993114a3620f5b6ed7eb6d4bdae9c4f62d671c
+Size (Math-Pari-2.030523.tar.gz) = 230001 bytes
+SHA1 (patch-Makefile.PL) = 54048800a19be290747feab0adee1a3dfd0b08b2
diff -r 0efc33c19e36 -r f00ae97d7d6a math/p5-Math-Pari/patches/patch-Makefile.PL
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/math/p5-Math-Pari/patches/patch-Makefile.PL Tue Aug 02 07:22:00 2022 +0000
@@ -0,0 +1,400 @@
+$NetBSD: patch-Makefile.PL,v 1.1 2022/08/02 07:22:00 ast Exp $
+
+Take Makefile.PL from version Math-Pari-2.01080900 to avoid
+Math::PariBuild and other conflicting build rules
+
+--- Makefile.PL.orig 2022-04-12 09:52:37.000000000 +0200
++++ Makefile.PL 2022-08-02 08:57:35.009435144 +0200
+@@ -1,40 +1,10 @@
+ # $Id: patch-Makefile.PL,v 1.1 2022/08/02 07:22:00 ast Exp $
+-use strict;
+-use Config '%Config';
+-
+-BEGIN { # Need to do before ExtUtils::MakeMaker caches them
+- my $c = tied(%Config) || \%Config;
+- if ($Config{gccversion} and grep /^OPTIMIZE=.*(?<![^\s=])-g(?!\S)/, @ARGV) { # XXXX Bug in Perl configuration: these should be in {optimize} only
+- ($c->{"${_}flags"} = $Config{"${_}flags"}) =~ s/(?<!\S)-(s|O(\d+|s|fast)?)(?!\S)//g for qw(cc cpp ld lddl);
+- } # gnukfreebsd(lddl) cygwin strawberry openbsd netbsd linux(lddl)
+- if ($^O eq 'solaris' and $Config{cc} eq 'gcc'
+- and ( ($c->{optimize} = $Config{optimize}) =~ s/(?<!\S)(-xarch=386|-xildoff)(?!\S)//g
+- or ($c->{cccdlflags} = $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
+- # See http://prefetch.net/blog/index.php/2006/07/29/building-perl-modules-for-solaris/
+- print <<EOP;
+-
+-... Broken config of gcc-on-Solaris detected! I would try to work around this.
+-... Reset: cccdlflags --> '$Config{cccdlflags}', optimize -> '$Config{optimize}'.
+-
+-EOP
+- }
+- ($c->{$_} = $Config{$_}) =~ s/(?<!\S)-flto(?!\S)// for qw(optimize $ldflags);
+-}
+-
+ use ExtUtils::MakeMaker;
+-
+-BEGIN {unshift @INC, 'utils'}
+-use Math::PariBuild;
++use Config '%Config';
+
+ # Uncomment and change this line if I fail to find it
+ # $paridir = "..";
+
+-# Some testing machine may run out of disk space. Bail out early.
+-{ open my $f, '>', '.test.diskwrite' or die "Cannot open the file `./.test.diskwrite' for write: $! (Disk full???!)";
+-}
+-
+ unless (-t STDOUT) { # Better reports if run with redirections
+ my $odef = select STDERR;
+ $| = 1;
+@@ -45,303 +15,63 @@
+
+ chmod 0400, 'typemap' if $^O =~ /cygwin/ and -f 'typemap' and not -r 'typemap'; # bug in some installations of cygwin???
+
+-my($ok23, $okPost23, $force_download, $force_patch, $parilib, $pariincludes, $parisrc, $paridir, $pari_version) = 1;
++my $pariprefix;
++my $addlibs;
++my $libpari = "pari";
+
+-grep {/^machine=(.*)$/i and $common::machine = $1} @ARGV;
+-grep {/^configure$/i and $common::do_configure = 1} @ARGV;
+-grep {/^paridir=(.*?)[\/\\]?$/i and $paridir = $1} @ARGV;
+-grep {/^pari_tgz=(.*?)[\/\\]?$/i and $parisrc = $1} @ARGV;
+-grep {/^force_download$/i and $force_download = 1} @ARGV;
+-grep {/^parilibs=(.*)$/i and $parilib = $1} @ARGV;
+-grep {/^pariincludes=(.*)$/i and $pariincludes = $1} @ARGV;
+-grep {/^version23_ok=(.*)$/i and $ok23 = $1} @ARGV;
+-grep {/^version_post23_ok=(.*)$/i and $okPost23 = $1} @ARGV;
+-grep {/^force_patch(=\d+)?$/i and $force_patch = (defined $1 ? $1 : 1)} @ARGV;
+-# grep {/^OPTIMIZE=(?<![^\s=])-g(?!\S)/i and $dbg = 1} @ARGV; # -Og (= optimize what does not interfere with debug) needs -g
+-
+-# The REx should anchored-match versions to skip
+-$common::skip_versions = $okPost23 ? '(?!)' : ($ok23 ? '2\.(?:[4-9]|\d\d+)\.' : '2\.(?:[3-9]|\d\d+)\.');
+-
+-@ARGV = grep !/^((machine|paridir|pari_tgz|parilibs|pariincludes|version23_ok|version_post23_ok|force_patch)=.*|configure|force_download)$/i, @ARGV;
+-
+-my %patchrc;
+-
+-$common::thread_engine = 'single';
+-$common::src = ($^O =~ /^MSWin/i and $Config{ptrsize} == 8) ? 'src64' : 'src';
+-
+-my($extra_inc, $define, $libs);
+-my $os = $Config{osname};
+-if ($parilib) {
+- die "One should define `pariincludes' together with 'parilib'" unless defined $pariincludes;
+- $pari_version = pari_formatted_version_from_includes "$pariincludes/include";
+- $define = '-DNO_HIGHLEVEL_PARI -DUSE_STANDALONE_PARILIB';
+- print <<EOP;
+-Trying to use existing PARI library (at $parilib)
+- (integer-formatted version $pari_version).
+-EOP
+-} else {
+- $paridir = find_pari_dir() unless defined $paridir or $parisrc or $force_download;
+- ($paridir, my @patch_rc) = download_and_patch_pari($parisrc, $force_download)
+- if !$paridir or $force_download;
+-
+-die <<EOD unless $paridir;
+-Could not find GP/PARI build directory, please run Makefile.PL
+-with paridir=/directory option.
+-EOD
+-
+- if (not $common::patches_run) {
+- if (-f (my $fn = "$paridir/.perl.patches")) {
+- my($h, @l, %s , $FAIL) = 0;
+- warn "\n\tIt looks like the directory was already patched.\n\tHere is the report from that patching session:\n",
+- do { if (open my $f, '<', $fn) {@l = <$f>}}, "\n";
+- if (@l) {
+- for my $l (@l) {
+- chomp $l;
+- $h = $1, next if $l =~ /^#\s*(\w+)/;
+- $s {$l}++ if $h eq 'Needed';
+- $FAIL++ if $h eq 'Failed';
+- }
+- $common::prepatched = \%s if keys %s;
+- $common::prepatched_fail = 1 if $FAIL;
+- }
+- } else {
+- my $force = (defined $force_patch ? $force_patch : ($paridir =~ m(^(\./)?pari)));
+- if ($force) {
+- @patch_rc = patch_pari($paridir);
+- } else {
+- warn "\n\tI won't auto-patch (`$paridir' is not a subdirectory) without option force_patch\n"
+- }
+- }
+- }
+- %patchrc = (patchrc => $patch_rc[0]) if @patch_rc;
++grep {/^pariprefix=(.*)$/i and $pariprefix = $1} @ARGV;
++grep {/^addlibs=(.*)$/i and $addlibs = $1} @ARGV;
++grep {/^libpari=(.*)$/i and $libpari = $1} @ARGV;
+
+- $define = '';
+- $pari_version = pari_formatted_version($paridir);
+- print <<EOP;
+-Found GP/PARI build directory in $paridir
+- (integer-formatted version $pari_version).
+-EOP
+- print <<EOP if $pari_version =~ /^20(\d\d)/ and $1 > 3; # may have specified a particular tgz...
+-
+- !!! Math::Pari does not support GP/PARI library versions after 2.3.*
+- !!! (although many features work; see the file ./README-after2_3_5).
+- !!! It seems you did force this particular version on Makefile.PL.
+- !!! The build system should not pick up such a version by itself...
+-
+-EOP
+- print <<EOP if $pari_version =~ /^2003/ and not -f "$paridir/src/graph/plotgnuplot.c";
+-
+- ### Math::Pari support of non-PS plotting functions of GP/PARI library
+- ### version 2.3.* requires patching GP/PARI source (I can auto-patch it).
+-
+- ### It looks like auto-patching did not happen!
+-
+-EOP
+- print <<EOP if $pari_version =~ /^2003/;
+-
+- ### In version 2.3.* of GP/PARI library, the test t/55_intnum.t takes
+- ### significant time to complete.
+-
+-EOP
+- print <<EOP if $pari_version =~ /^2001/;
+-
+- ### GP/PARI library version 2.1.* has many problems fixed in versions 2.3.*.
+-
+- ### Especially important are the problems with symbols `hiremainder' and
+- ### `overflow' - if your build fails and error messages contain these
+- ### words, updating to 2.3.* might allow your use of fast processor-specific
+- ### assembler code.)
+-
+- ### Switching to 2.3.* should be as simple as giving Makefile.PL an option
+- ### version23_ok=1
+- ### (if you or Makefile.PL already downloaded-and-extracted version-2.1.*
+- ### distribution, give an extra option, force_download).
+- ### Alternatively, give option
+- ### paridir=DIRECTORY-of-extracted-distribution
+-
+- ### However: v.2.3.* REQUIRES patching for full support of plotting.
+- ### (And I can auto-patch it!)
+-
+-EOP
+- $common::pari_version = $pari_version;
+- $common::main_paridir = $paridir;
+- *MY::postamble = \&xMY::postamble;
+-
+- 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}'.
+-EOP
+-
+- $define .= " -DPARI_VERSION_EXP=$pari_version -DDEBUG_PARI";
+- $define .= " -DUSE_SLOW_ARRAY_ACCESS -DUSE_SLOW_NARGS_ACCESS" if $] >= 5.009;
+- $libs = "-lm";
+- my $noexp2 = ''; # Should be used for generation of paricfg.h (not used anymore!)
+-
+- if ($os eq "solaris") {
+- # Some older versions needed -lsunmath to import exp2(). This is
+- # probably not needed anymore (though can speed things up).
+-
+- # Below -R specifies the path to search for this file when the
+- # program will run, -L the path to search when the program is linked
+- # @sc_dirs = '/opt/SUNWspro/lib' if -d '/opt/SUNWspro/lib';
+- # @sc_dirs = </opt/SUNWspro/SC*/lib> unless @sc_dirs;
+- # if (@sc_dirs) {
+- # $libs .= " -R$sc_dirs[-1] -L$sc_dirs[-1] -lsunmath -lm";
+- # } else {
+- # #warn "Cannot find SUNWspro dirs, needed for -lsunmath, using NOEXP2.\n";
+- $noexp2 = 1;
+- # }
+- } elsif ($os eq "os2") {
+- $noexp2 = 1;
+- $define .= " -DMALLOC_PROCS";
+- } elsif ($os eq 'linux') {
+- $noexp2 = 1;
+- }
++@ARGV = grep !/^((pariprefix|addlibs|libpari)=.*)$/i, @ARGV;
++my $define = "-DPARI_VERSION_EXP=" . get_pari_formatted_version();
+
+- my %opts;
++# We want to find the offset of the least significant byte
++# of SV.flags inside an SV.
++# It is enough to find the offset of the least significant byte inside a U32.
++# (Needed for recognizing Perl code supplied to lisseq and lisexpr.)
+
+- build_tests $paridir; # Convert the test suite
+- make_pod 'libPARI.pod', '-to_pod', $paridir; # Now the docs
+- make_pod 'libPARI.dumb.pod', '-to_dumb_pod', $paridir;
+- # ... and paricfg.h
+- %opts = build_paricfg($paridir, $common::do_configure, $pari_version);
+-
+- if ($ENV{MATH_PARI_REPORT_CODES}) {
+- # Check the correspondence between string interfaces and numeric interfaces
+- my %codes;
+- my %names;
+- ep_in_version($pari_version);
+- ep_codes_from_file("$paridir/src/language/init.c", %codes, %names);
+- ep_codes_from_file("$paridir/src/gp/highlvl.c", %codes, %names);
+- # EpValence reworked in 2.2.7; when exactly was it redone??? XXXX
+- unless ($pari_version > 2002006 or ep_hash_report(%codes)) {
+- print STDERR "Problems with numeric interface codes noted:\n";
+- ep_hash_report(%codes, %names, \*STDERR);
+- }
+- }
++$offset = index($Config{byteorder}, "1");
Home |
Main Index |
Thread Index |
Old Index