Opened 10 years ago
Closed 10 years ago
#9860 closed enhancement (fixed)
Port changes in PARI 2.3.5.p4 (#9722) to current 2.4.3
Reported by: | leif | Owned by: | leif |
---|---|---|---|
Priority: | major | Milestone: | sage-4.6 |
Component: | packages: standard | Keywords: | |
Cc: | Merged in: | sage-4.6.alpha0 | |
Authors: | Leif Leonhardy, Jeroen Demeyer | Reviewers: | Jeroen Demeyer, Leif Leonhardy |
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description (last modified by )
Some fixes to PARI 2.3.5.p2 from #9722 had to be ported to the current NewPARI spkg. The new PARI 2.4.3.p5 spkg here contains some further changes (including some on Sage's side, mostly clean-up), while other issues have meanwhile been fixed upstream.
This package is intended to be tested with Sage 4.6.prealpha3. If you want to test it with Sage 4.5.3.*, apart from installing this spkg here, you also need to apply the sagelib and extcode patches from #9343. See the wiki page for detailed instructions. You can also download Sage 4.6.prealpha4, which includes the new package with all changes made here.
New (complete) spkg up at http://sage.math.washington.edu/home/jdemeyer/spkg/pari-2.4.3.svn-12577.p5.spkg
pari-2.4.3.svn-12577.p5 (Leif Leonhardy, Jeroen Demeyer, September 5th, 2010)
- Added patches to:
- config/get_config_options:
- Make invalid arguments to "--graphic" a "Configure" error (rather than potentially running into *compilation* errors later).
- config/get_fltk: (see also/ported from #9722)
- Add libstdc++ to the libraries (to support Fedora 13 et al.).
- Also check the presence of the FLTK include directory to prevent compilation errors on broken installations.
- config/get_X11: (see also/ported from #9722)
- Also search */lib64/* directories when doing a 64-bit build.
- Give more specific messages.
- config/get_config_options:
- Slightly extended existing patch to src/kernel/gmp/mp.c:
- Allow disabling PARI's use of "GMP internals" by preprocessor directive (i.e. by adding "-DPARI_DONT_USE_GMP_INTERNALS" to CFLAGS). Brief explanation added.
- spkg-install:
- Don't override user-specified CFLAGS (w.r.t. optimization, unless SAGE_DEBUG=yes).
- Handle PARI_EXTRA_OPTS properly, and print informative messages (regarding graphics support for plotting).
- Recognize SAGE_TUNE_PARI in addition to SAGE_TUNE_pari, and add "--tune" to PARI_EXTRA_OPTS if self-tuning was requested.
- Clear/unset lots of (environment) variables used by PARI that might unintentionally get their values from user settings.
- Quote *all* occurrences of SAGE_LOCAL (and some other expressions).
- Use $UNAME instead of
uname
everywhere, use "elif ...". - *Always* use $MAKE (changed for "install-data").
- Begin all error messages with "Error".
- Removed useless tests of $? at end.
- Some clean-up (typos, formatting); some comments, some messages added.
- spkg-check:
- Use $MAKE instead of "make".
- Don't override user-specified CFLAGS (w.r.t. optimization, unless SAGE_DEBUG=yes).
- Begin error message with "Error".
- Some clean-up.
- Slight corrections to SPKG.txt.
- Updated patches/README.txt, some cosmetic changes.
- Remove patch for config/Makefile.SH and add upstream fix instead in spkg-make.
- Add upstream fix for src/tune/tune.c which should fix tuning.
- Add -O0 to CFLAGS in spkg-make to speed up compiling (the output of the compiling is not used anyway).
Attachments (3)
Change History (18)
Changed 10 years ago by
comment:1 Changed 10 years ago by
- Description modified (diff)
- Status changed from new to needs_review
comment:2 Changed 10 years ago by
I've only tested this with a couple of variations on parameters and installed libraries / graphics packages on Ubuntu 10.04 x86_64 and Fedora 13 x86.
Should work on other systems as well... ;-)
comment:3 follow-up: ↓ 4 Changed 10 years ago by
What do I need to do to test this - just download the package - do I need to patch anything else?
I've done:
- Downloaded and installed http://spkg-upload.googlecode.com/files/pari-2.4.3.svn-12577.p5.spkg
- Nothing else changed from 4.5.3.alpha2
- No attempt to tune code
drkirkby@hawk:~/5/sage-4.5.3.alpha2$ ./sage -b ---------------------------------------------------------- sage: Building and installing modified Sage library files. Installing c_lib gcc -o src/convert.pic.o -c -fPIC -I/export/home/drkirkby/5/sage-4.5.3.alpha2/local/include -I/export/home/drkirkby/5/sage-4.5.3.alpha2/local/include/python2.6 -I/export/home/drkirkby/5/sage-4.5.3.alpha2/local/include/NTL -Iinclude src/convert.c g++ -o libcsage.so -shared src/convert.pic.o src/interrupt.pic.o src/mpn_pylong.pic.o src/mpz_pylong.pic.o src/mpz_longlong.pic.o src/stdsage.pic.o src/gmp_globals.pic.o src/ZZ_pylong.pic.o src/ntl_wrap.pic.o -L/export/home/drkirkby/5/sage-4.5.3.alpha2/local/lib -L/export/home/drkirkby/5/sage-4.5.3.alpha2/local/lib/python/config -lntl -lgmp -lpari -lpython2.6 Updating Cython code.... Execute 0 commands (using 0 threads) Time to execute 0 commands: 0.0976297855377 seconds Finished compiling Cython code (time = 3.07916307449 seconds) running install running build running build_py running build_ext Total time spent compiling C/C++ extensions: 0.913223028183 seconds. running install_lib running install_egg_info Removing /export/home/drkirkby/5/sage-4.5.3.alpha2/local/lib/python2.6/site-packages/sage-0.0.0-py2.6.egg-info Writing /export/home/drkirkby/5/sage-4.5.3.alpha2/local/lib/python2.6/site-packages/sage-0.0.0-py2.6.egg-info real 0m8.727s user 0m1.339s sys 0m0.727s drkirkby@hawk:~/5/sage-4.5.3.alpha2$ make ptestlong cd spkg && ./install all 2>&1 | tee -a ../install.log make[1]: Entering directory `/export/home/drkirkby/5/sage-4.5.3.alpha2/spkg' make[1]: Nothing to be done for `all'. make[1]: Leaving directory `/export/home/drkirkby/5/sage-4.5.3.alpha2/spkg' real 0m0.018s user 0m0.003s sys 0m0.003s To install gap, gp, singular, etc., scripts in a standard bin directory, start sage and type something like sage: install_scripts('/usr/local/bin') at the Sage command prompt. To build the documentation, run make doc Sage build/upgrade complete! ./sage -docbuild all html 2>&1 | tee -a dochtml.log sphinx-build -b html -d /export/home/drkirkby/5/sage-4.5.3.alpha2/devel/sage/doc/output/doctrees/en/website /export/home/drkirkby/5/sage-4.5.3.alpha2/devel/sage/doc/en/website /export/home/drkirkby/5/sage-4.5.3.alpha2/devel/sage/doc/output/html/en/website *** bug in PARI/GP (Segmentation Fault), please report ^Cmake: *** [doc-html] Interrupt
IIRC, the changes from sage-4.5.3.alpha2
to sage-4.5.3.rc0
were just a few Solaris-specific changes which would not all all doc tests to pass, but were not need to actually get things working.
This is on an OpenSolaris (Xeon processor) machine. I've not tried on anything else.
I'm rather hoping I've forgot something - in which case you have time to review #9603 !
Dave
comment:4 in reply to: ↑ 3 ; follow-up: ↓ 7 Changed 10 years ago by
Replying to drkirkby:
What do I need to do to test this - just download the package - do I need to patch anything else?
You also need to apply the sagelib and extcode patches from #9343. Or easier: download http://sage.math.washington.edu/home/jdemeyer/dist/sage-4.6.prealpha3.tar, install that and then install the new pari spkg.
comment:5 Changed 10 years ago by
- Description modified (diff)
comment:6 follow-up: ↓ 10 Changed 10 years ago by
I have made a few small changes to the pari spkg and put the result at http://sage.math.washington.edu/home/jdemeyer/spkg/pari-2.4.3.svn-12577.p5.spkg (I kept the p5 version number).
comment:7 in reply to: ↑ 4 ; follow-up: ↓ 8 Changed 10 years ago by
Replying to jdemeyer:
Replying to drkirkby:
What do I need to do to test this - just download the package - do I need to patch anything else?
You also need to apply the sagelib and extcode patches from #9343. Or easier: download http://sage.math.washington.edu/home/jdemeyer/dist/sage-4.6.prealpha3.tar, install that and then install the new pari spkg.
It would be good if you could make a new tar file with all the changes in place - i.e. make a sage-4.6.prealpha4.tar
Dave
comment:8 in reply to: ↑ 7 Changed 10 years ago by
comment:9 Changed 10 years ago by
- Description modified (diff)
comment:10 in reply to: ↑ 6 Changed 10 years ago by
Replying to jdemeyer:
I have made a few small changes to the pari spkg and put the result at http://sage.math.washington.edu/home/jdemeyer/spkg/pari-2.4.3.svn-12577.p5.spkg (I kept the p5 version number).
I'm ok with your changes ("positive review"). Not very surprisingly Sage 4.6.prealpha4 also passed all tests. Tuning on a Core2 worked, too, at least did pass without errors. ;-)
The way we handle the patches now (without the patched replacement files being under revision control) is a bit dangerous though. Perhaps we should also add some script to generate the patches from patches/files/*
and one to just make sure they're in sync.
comment:11 Changed 10 years ago by
- Reviewers set to Leif Leonhardy, Jeroen Demeyer
- Status changed from needs_review to positive_review
Leif: your patch looks good on visual inspection. Since it fixes all known build issues, I give it positive review.
comment:12 follow-up: ↓ 13 Changed 10 years ago by
- Reviewers changed from Leif Leonhardy, Jeroen Demeyer to Jeroen Demeyer, Leif Leonhardy
Otherwise looks a bit funny. Thanks though. ;-)
I think we should report some of the changes upstream when our PARI has successfully reached some Sage 4.6.{alpha,rc}.
comment:13 in reply to: ↑ 12 Changed 10 years ago by
Replying to leif:
I think we should report some of the changes upstream when our PARI has successfully reached some Sage 4.6.{alpha,rc}.
Agreed.
comment:14 Changed 10 years ago by
P.S.: Attempting to build with Qt as the graphics back-end is still broken in some constellations (i.e. may lead to build errors, too), since the code apparently expects Qt <= 3 and some (Qt) tools PARI doesn't look for. I haven't yet worked on config/get_Qt
though.
comment:15 Changed 10 years ago by
- Merged in set to sage-4.6.alpha0
- Resolution set to fixed
- Status changed from positive_review to closed
Apply to pari-2.4.3.svn-12577.p4.spkg. Note that added/changed files in
patches/files
are not included here!