Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37753625
en ru br
Репозитории ALT
S:2.030523-alt1.1
5.1: 2.010709-alt2
4.1: 2.010709-alt1
4.0: 2.010709-alt1
www.altlinux.org/Changes

Группа :: Разработка/Perl
Пакет: perl-Math-Pari

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: Math-Pari-2.030518-system-pari.patch
Скачать


--- Makefile.PL
+++ Makefile.PL
@@ -63,6 +63,16 @@ if ($parilib) {
 Trying to use existing PARI library (at $parilib)
      (integer-formatted version $pari_version).
 EOP
+  $common::parilib = $parilib;
+  $define .= " -DPARI_VERSION_EXP=$pari_version";
+  my $offset = index($Config{byteorder}, "1");
+  $offset = 3 if $offset > 3;	# SvFLAGS is actually I32
+  $define .= " -DLSB_in_U32=$offset";
+  my $longsize = length(eval { pack 'l!', 1 } or pack 'l', 1);
+  my $perl_int_size = $Config{'ivsize'} || $Config{'intsize'}
+          or die "Can't deduce Perl int size";
+  $define .= ' -DLONG_SHORTER_THAN_IV' if $perl_int_size > $longsize;
+  $define .= ' -Derr=pari_err'; # On linux it can get a wrong dynamic loading
 } else {
   $paridir   = find_pari_dir() unless defined $paridir or $parisrc or $force_download;
   ($paridir, my @patch_rc) = download_and_patch_pari($parisrc, $force_download)
@@ -253,9 +263,11 @@ EOP
 		  LIBS	     =>  $parilib,
 		  INC	     =>  "-I $pariincludes/include -I $pariincludes/src",
 		 ) :
-		 (MYEXTLIB   =>  'libPARI/libPARI$(LIB_EXT)')),
+		 (MYEXTLIB   =>  'libPARI/libPARI$(LIB_EXT)',
 		  LIBS	     =>  $libs,
 		  INC	     =>  $extra_inc . ' -I $(PARI_DIR_SRC)/headers -I $(PARI_DIR_SRC) -I ./libPARI',
+                 )
+               ),
 	       VERSION_FROM  => 'Pari.pm',
     ($] >= 5.005 ?     ## Add these new keywords supported since 5.005
       (ABSTRACT_FROM  => 'Pari.pm', # retrieve abstract from module
--- Pari.xs
+++ Pari.xs
@@ -8,6 +8,7 @@
 #ifdef USE_STANDALONE_PARILIB
 #  include <pari/pari.h>
 #  include <pari/paripriv.h>
+#  include <language/anal.h>
 #else
 #  include <pari.h>
 #  if PARI_VERSION_EXP < 2011000	/* Probably much earlier too... */
--- utils/Math/PariBuild.pm
+++ utils/Math/PariBuild.pm
@@ -254,7 +254,7 @@ sub extract_pari_archive ($) {
     return $dir;
 }
 
-sub fmt_version {sprintf "%03d%03d%03d", split /\./, shift}
+sub fmt_version {sprintf "%d%03d%03d", split /\./, shift}
 
 sub pari_formatted_version_from_includes($) {	# Unsupported; to enable parilib option; based on
     my $prefix = shift;			#  http://cvsweb.netbsd.org/bsdweb.cgi/~checkout~/pkgsrc/math/p5-Math-Pari/patches/patch-aa
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin