mirror of
https://src.fedoraproject.org/rpms/sagemath.git
synced 2025-04-22 11:45:56 -04:00
Update to sagemath 8.0
This commit is contained in:
parent
b78abd5373
commit
abc6d11c12
27 changed files with 290 additions and 655 deletions
231
sagemath.spec
231
sagemath.spec
|
@ -1,9 +1,7 @@
|
|||
%global __provides_exclude_from .*/site-packages/.*\\.so
|
||||
|
||||
%bcond_with bundled_pari
|
||||
%bcond_with bundled_pexpect
|
||||
%bcond_without bundled_ipython
|
||||
%bcond_with bundled_cysignals
|
||||
%bcond_with bundled_ipython
|
||||
%bcond_without install_hack
|
||||
|
||||
# for faster full rpm test builds
|
||||
|
@ -33,27 +31,21 @@
|
|||
%global SAGE_TIMEOUT 60
|
||||
%global SAGE_TIMEOUT_LONG 180
|
||||
|
||||
%global conway_polynomials_pkg conway_polynomials-0.4
|
||||
%if %{with bundled_cysignals}
|
||||
%global cysignals_pkg cysignals-1.3.2
|
||||
%endif
|
||||
%global conway_polynomials_pkg conway_polynomials-0.5
|
||||
%global elliptic_curves_pkg elliptic_curves-0.8
|
||||
%global flintqs_pkg flintqs-1.0
|
||||
%global graphs_pkg graphs-20161026
|
||||
%if %{with bundled_ipython}
|
||||
%global ipython_pkg ipython-5.1.0
|
||||
%endif
|
||||
%if %{with bundled_pari}
|
||||
%global pari_pkg pari-2.9.1
|
||||
%endif
|
||||
%if %{with bundled_pexpect}
|
||||
%global pexpect_pkg pexpect-4.1.0
|
||||
%endif
|
||||
%global polytopes_db_pkg polytopes_db-20120220
|
||||
%global rubiks_pkg rubiks-20070912
|
||||
%global sagenb_pkg sagenb-0.13
|
||||
%global sagenb_pkg sagenb-1.0.1
|
||||
%global sagetex_pkg sagetex-3.0
|
||||
%global Sphinx_pkg Sphinx-1.4.4
|
||||
%global Sphinx_pkg Sphinx-1.5.3
|
||||
|
||||
%global SAGE_ROOT %{_libdir}/sagemath
|
||||
%global SAGE_LOCAL %{SAGE_ROOT}/local
|
||||
|
@ -67,8 +59,8 @@
|
|||
Name: sagemath
|
||||
Group: Applications/Engineering
|
||||
Summary: A free open-source mathematics software system
|
||||
Version: 7.6
|
||||
Release: 6%{?dist}
|
||||
Version: 8.0
|
||||
Release: 1%{?dist}
|
||||
# The file ${SAGE_ROOT}/COPYING.txt is the upstream license breakdown file
|
||||
# Additionally, every $files section has a comment with the license name
|
||||
# before files with that license
|
||||
|
@ -114,82 +106,72 @@ Patch8: %{name}-maxima.patch
|
|||
# execute 4ti2 programs in $PATH not in $SAGE_ROOT/local/bin
|
||||
Patch9: %{name}-4ti2.patch
|
||||
|
||||
# http://trac.sagemath.org/sage_trac/ticket/12992
|
||||
# http://pari.math.u-bordeaux.fr/cgi-bin/bugreport.cgi?bug=1317
|
||||
Patch10: %{name}-pari.patch
|
||||
|
||||
# use jmol itself to export preview images
|
||||
# FIXME besides not using X and told so, fails if DISPLAY is not set
|
||||
Patch11: %{name}-jmol.patch
|
||||
Patch10: %{name}-jmol.patch
|
||||
|
||||
# only cremona mini database built and installed
|
||||
# FIXME add a package with the full cremona database
|
||||
# FIXME actually it should be already available in pari-elldata
|
||||
Patch12: %{name}-cremona.patch
|
||||
Patch11: %{name}-cremona.patch
|
||||
|
||||
# lrslib is a requires
|
||||
Patch13: %{name}-lrslib.patch
|
||||
Patch12: %{name}-lrslib.patch
|
||||
|
||||
# correct path to the nauty geng program
|
||||
# http://cs.anu.edu.au/~bdm/nauty/
|
||||
# http://pallini.di.uniroma1.it/
|
||||
Patch14: %{name}-nauty.patch
|
||||
Patch13: %{name}-nauty.patch
|
||||
|
||||
# gap hap package not (yet) available
|
||||
# http://www-gap.mcs.st-and.ac.uk/Packages/hap.html
|
||||
Patch15: %{name}-gap-hap.patch
|
||||
Patch14: %{name}-gap-hap.patch
|
||||
|
||||
# correct path to Lfunction include
|
||||
Patch16: %{name}-lcalc.patch
|
||||
Patch15: %{name}-lcalc.patch
|
||||
|
||||
# avoid assertion in coin backend
|
||||
Patch17: %{name}-cbc.patch
|
||||
Patch16: %{name}-cbc.patch
|
||||
|
||||
# Use system gap directories
|
||||
Patch18: %{name}-libgap.patch
|
||||
Patch17: %{name}-libgap.patch
|
||||
|
||||
# Build fes
|
||||
Patch19: %{name}-fes-build.patch
|
||||
Patch18: %{name}-fes-build.patch
|
||||
# Disable fes
|
||||
Patch20: %{name}-fes.patch
|
||||
Patch19: %{name}-fes.patch
|
||||
|
||||
# Side effect of using distro packages
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=974769
|
||||
Patch21: %{name}-sympy.patch
|
||||
Patch20: %{name}-sympy.patch
|
||||
|
||||
# Fix a name clash with NTL
|
||||
Patch22: %{name}-ntl.patch
|
||||
Patch21: %{name}-ntl.patch
|
||||
|
||||
# Correct unable to start QEPCAD within sage
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1243590
|
||||
Patch23: %{name}-qepcad.patch
|
||||
Patch22: %{name}-qepcad.patch
|
||||
|
||||
# Correct path to arb headers
|
||||
Patch24: %{name}-arb.patch
|
||||
Patch23: %{name}-arb.patch
|
||||
|
||||
# Adapt to header file changes in givaro 4 and linbox 1.4
|
||||
Patch25: %{name}-givaro.patch
|
||||
Patch24: %{name}-givaro.patch
|
||||
|
||||
# No support for f" notation
|
||||
Patch26: %{name}-nofstring.patch
|
||||
Patch25: %{name}-nofstring.patch
|
||||
|
||||
# Add missing include paths
|
||||
Patch27: %{name}-includes.patch
|
||||
Patch26: %{name}-includes.patch
|
||||
|
||||
# https://trac.sagemath.org/ticket/20926
|
||||
# #error This file requires compiler and library support for the ISO C++ \
|
||||
# 2011 standard. This support must be enabled with the -std=c++11 \
|
||||
# or -std=gnu++11 compiler options.
|
||||
Patch28: %{name}-gcc6.patch
|
||||
Patch27: %{name}-gcc6.patch
|
||||
|
||||
# Use atlas blas
|
||||
Patch29: %{name}-atlas.patch
|
||||
|
||||
# Update for python-flask-0.11.1
|
||||
Patch30: %{name}-flask.patch
|
||||
|
||||
# Minor adaptation to latest singular
|
||||
Patch31: %{name}-singular.patch
|
||||
Patch28: %{name}-atlas.patch
|
||||
|
||||
BuildRequires: 4ti2
|
||||
BuildRequires: arb-devel
|
||||
|
@ -198,7 +180,7 @@ BuildRequires: brial-devel
|
|||
BuildRequires: cddlib-tools
|
||||
BuildRequires: cliquer-devel
|
||||
BuildRequires: coin-or-Cbc-devel
|
||||
BuildRequires: cryptominisat-devel
|
||||
#BuildRequires: cryptominisat-devel
|
||||
BuildRequires: Cython >= 0.24.1
|
||||
BuildRequires: desktop-file-utils
|
||||
BuildRequires: dos2unix
|
||||
|
@ -247,19 +229,14 @@ BuildRequires: nauty
|
|||
BuildRequires: ntl-devel
|
||||
BuildRequires: numpy
|
||||
BuildRequires: palp
|
||||
%if %{with bundled_pari}
|
||||
BuildConflicts: pari-devel
|
||||
%else
|
||||
BuildRequires: pari-devel
|
||||
BuildRequires: pari-gp
|
||||
%endif
|
||||
BuildRequires: planarity-devel
|
||||
BuildRequires: ppl-devel
|
||||
BuildRequires: pynac-devel
|
||||
BuildRequires: python2-devel
|
||||
%if %{without bundled_cysignals}
|
||||
BuildRequires: python-cypari2-devel
|
||||
BuildRequires: python-cysignals-devel
|
||||
%endif
|
||||
BuildRequires: python-flask-autoindex
|
||||
BuildRequires: python-flask-babel
|
||||
BuildRequires: python-flask-openid
|
||||
|
@ -324,9 +301,7 @@ Requires: nauty
|
|||
Requires: palp
|
||||
Requires: pari-gp
|
||||
Requires: python-brial
|
||||
%if %{without bundled_cysignals}
|
||||
Requires: python-cysignals
|
||||
%endif
|
||||
Requires: python-crypto
|
||||
Requires: python-cvxopt
|
||||
Requires: python-docutils
|
||||
|
@ -608,18 +583,6 @@ computations, and plots from the Sage mathematics software suite
|
|||
%prep
|
||||
%setup -q -n sage-%{version}
|
||||
|
||||
%if %{with bundled_cysignals}
|
||||
pushd build/pkgs/cysignals
|
||||
tar jxf ../../../upstream/%{cysignals_pkg}.tar.bz2
|
||||
mv %{cysignals_pkg} src
|
||||
if [ %{__isa_bits} = "64" ]; then
|
||||
for file in $(find . -name cysignals-CSI); do
|
||||
sed -i "s/'lib'/'%{_lib}'/" $file
|
||||
done
|
||||
fi
|
||||
popd
|
||||
%endif
|
||||
|
||||
pushd build/pkgs/conway_polynomials
|
||||
tar jxf ../../../upstream/%{conway_polynomials_pkg}.tar.bz2
|
||||
mv %{conway_polynomials_pkg} src
|
||||
|
@ -647,20 +610,6 @@ pushd build/pkgs/ipython
|
|||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_pari}
|
||||
pushd build/pkgs/pari
|
||||
tar zxf ../../../upstream/%{pari_pkg}.tar.gz
|
||||
mv %{pari_pkg} src
|
||||
pushd src
|
||||
for diff in ../patches/*.patch; do
|
||||
patch -p1 < $diff
|
||||
done
|
||||
# Temporary workaround: redefining GCC_VERSION kills the build
|
||||
sed -i 's/GCC_VERSION/PARI_&/' config/paricfg.h.SH
|
||||
popd
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_pexpect}
|
||||
pushd build/pkgs/pexpect
|
||||
tar zxf ../../../upstream/%{pexpect_pkg}.tar.gz
|
||||
|
@ -721,11 +670,7 @@ popd
|
|||
%patch7
|
||||
%patch8
|
||||
%patch9
|
||||
|
||||
%if %{without bundled_pari}
|
||||
%patch10
|
||||
%endif
|
||||
|
||||
%patch11
|
||||
%patch12
|
||||
%patch13
|
||||
|
@ -733,38 +678,29 @@ popd
|
|||
%patch15
|
||||
%patch16
|
||||
%patch17
|
||||
%patch18
|
||||
|
||||
%if %{with fes}
|
||||
%patch19
|
||||
%patch18
|
||||
%else
|
||||
%patch20
|
||||
%patch19
|
||||
%endif
|
||||
|
||||
%patch20
|
||||
%patch21
|
||||
%patch22
|
||||
%patch23
|
||||
%patch24
|
||||
%patch25
|
||||
%patch26
|
||||
|
||||
%patch27
|
||||
%patch28
|
||||
%patch29
|
||||
%patch30
|
||||
%patch31
|
||||
|
||||
sed -e 's|@@SAGE_ROOT@@|%{SAGE_ROOT}|' \
|
||||
-e 's|@@SAGE_DOC@@|%{SAGE_DOC}|' \
|
||||
-i src/sage/env.py
|
||||
|
||||
%if %{with bundled_cysignals}
|
||||
sed -e 's|@@CYSIGNALS@@|%{_builddir}%{python_sitearch}/cysignals|' \
|
||||
-i src/setup.py
|
||||
%else
|
||||
sed -e 's|@@CYSIGNALS@@|%{python_sitearch}/cysignals|' \
|
||||
-i src/setup.py
|
||||
%endif
|
||||
|
||||
sed -e "s|, 'flask-oldsessions>=0.10'||" \
|
||||
-e "s|'http://github.com/mitsuhiko/flask-oldsessions/tarball/master#egg=flask-oldsessions-0.10'||" \
|
||||
|
@ -829,41 +765,6 @@ pushd build/pkgs/ipython/src
|
|||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_pari}
|
||||
# Build bundled pari-2.8
|
||||
pushd build/pkgs/pari/src
|
||||
./Configure --prefix=%{_builddir} \
|
||||
--without-readline --with-gmp \
|
||||
--kernel=gmp --graphic=none
|
||||
sed -i 's|%{_builddir}|%{_prefix}|g' Olinux-*/paricfg.h
|
||||
make %{?_smp_mflags} gp
|
||||
make install DESTDIR=""
|
||||
cp -p src/language/anal.h %{_builddir}/include/pari/anal.h
|
||||
popd
|
||||
%endif
|
||||
|
||||
# Generate pari interface
|
||||
pushd src
|
||||
%__python2 -c "from sage_setup.autogen.interpreters import rebuild; rebuild('sage/ext/interpreters')"
|
||||
%__python2 -c "from sage_setup.autogen.pari import rebuild; rebuild()"
|
||||
popd
|
||||
|
||||
%if %{with bundled_pari}
|
||||
# Make temporary headers and static library visible
|
||||
sed -i 's|\(^ include_directories = \[SAGE_INC,\)|\1 "%{_builddir}/include",|' \
|
||||
src/sage/env.py
|
||||
sed -i 's|\(^extra_link_args = \[\) \]|\1"-L%{_builddir}/lib"\]|' \
|
||||
src/setup.py
|
||||
%endif
|
||||
|
||||
%if %{with bundled_cysignals}
|
||||
pushd build/pkgs/cysignals/src
|
||||
%__python2 setup.py build
|
||||
%__python2 setup.py install --root %{_builddir}
|
||||
popd
|
||||
export PYTHONPATH=%{_builddir}%{python_sitearch}:$PYTHONPATH
|
||||
%endif
|
||||
|
||||
%if %{with cython_hack}
|
||||
cp -far %{python_sitearch}/Cython %{_builddir}%{python_sitearch}
|
||||
BASE=$PWD/build/pkgs/cython/patches/
|
||||
|
@ -927,9 +828,6 @@ export SAGE_ETC=%{buildroot}%{SAGE_ETC}
|
|||
export SAGE_EXTCODE=%{buildroot}%{SAGE_ETC}
|
||||
export SAGE_DOC=%{buildroot}%{SAGE_DOC}
|
||||
export SAGE_PYTHONPATH=%{buildroot}%{SAGE_PYTHONPATH}
|
||||
%if %{with bundled_pari}
|
||||
export LD_LIBRARY_PATH=%{_builddir}/lib:$LD_LIBRARY_PATH
|
||||
%endif
|
||||
export DESTDIR=%{buildroot}
|
||||
export SAGE_DEBUG=no
|
||||
export DOT_SAGE=/tmp/sage$$
|
||||
|
@ -950,17 +848,6 @@ ln -sf %{_libdir} $SAGE_LOCAL/lib
|
|||
ln -sf %{_includedir} $SAGE_LOCAL/include
|
||||
ln -sf %{_datadir} $SAGE_LOCAL/share
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%if %{with bundled_cysignals}
|
||||
pushd build/pkgs/cysignals/src
|
||||
pushd docs
|
||||
%__make html
|
||||
popd
|
||||
%__python2 setup.py install --root %{buildroot}
|
||||
mv %{buildroot}%{_bindir}/cysignals* $SAGE_LOCAL/bin
|
||||
popd
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
pushd src/ext
|
||||
mkdir -p $SAGE_ETC
|
||||
|
@ -996,13 +883,6 @@ pushd src
|
|||
%endif
|
||||
popd
|
||||
|
||||
%if %{with bundled_pari}
|
||||
# Revert change to make temporary headers and static library visible
|
||||
# Making it search for the installed sagemath path
|
||||
sed -i 's|\(^ include_directories = \[SAGE_INC,\).*|\1|' \
|
||||
%{buildroot}%{SAGE_SRC}/sage/env.py
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
pushd build/pkgs/sagenb/src
|
||||
rm -f %{buildroot}%{python_sitearch}/sagenb/data/sage3d/sage3d
|
||||
|
@ -1035,9 +915,7 @@ pushd src/bin
|
|||
ln -sf %{_bindir}/jmol jmol
|
||||
ln -sf %{_bindir}/python sage.bin
|
||||
ln -sf %{_bindir}/python python
|
||||
%if %{without bundled_pari}
|
||||
ln -sf %{_bindir}/gp sage_pari
|
||||
%endif
|
||||
ln -sf %{_bindir}/gap gap_stamp
|
||||
ln -sf %{_bindir}/gmp-ecm ecm
|
||||
popd
|
||||
|
@ -1281,10 +1159,6 @@ perl -pi -e 's|%{buildroot}||g;' \
|
|||
|
||||
# Script was used to build documentation
|
||||
perl -pi -e 's|%{buildroot}||g;s|^##||g;' %{buildroot}%{_bindir}/sage
|
||||
%if %{with bundled_cysignals}
|
||||
perl -pi -e 's|%{buildroot}||;' \
|
||||
%{buildroot}%{python_sitearch}/cysignals/__init__.pxd
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Fix links
|
||||
|
@ -1351,23 +1225,6 @@ rm -r %{buildroot}%{python_sitearch}/sagenb/data/sage3d
|
|||
[ -d %{buildroot}%{SAGE_SRC}/build ] &&
|
||||
rm -r %{buildroot}%{SAGE_SRC}/build
|
||||
|
||||
%if %{with bundled_pari}
|
||||
install -D -m 755 %{_builddir}/bin/gp-2.8 %{buildroot}%{SAGE_LOCAL}/bin/gp-2.8
|
||||
for dest in gp sage_pari; do
|
||||
ln -sf gp-2.8 %{buildroot}%{SAGE_LOCAL}/bin/$dest
|
||||
done
|
||||
install -D -m 755 %{_builddir}/lib/libpari-gmp-2.8.so.0.0.0 \
|
||||
%{buildroot}%{SAGE_ROOT}/lib/libpari-gmp-2.8.so.0.0.0
|
||||
ln -s libpari-gmp-2.8.so.0.0.0 \
|
||||
%{buildroot}%{SAGE_ROOT}/lib/libpari-gmp-2.8.so.0
|
||||
install -D -m 644 %{_builddir}/share/pari/pari.desc \
|
||||
%{buildroot}%{SAGE_LOCAL}/pari.desc
|
||||
|
||||
# make sure pari is in link path
|
||||
ln -s libpari-gmp-2.8.so.0.0.0 %{buildroot}%{SAGE_ROOT}/lib/libpari.so
|
||||
perl -pi -e 's|(libdirs = cblas_library_dirs)|$1 + \["%{SAGE_ROOT}/lib"\]|;' %{buildroot}%{python_sitearch}/sage/misc/cython.py
|
||||
%endif
|
||||
|
||||
%if %{without install_hack}
|
||||
# remove sage_setup
|
||||
rm -r %{buildroot}%{python_sitearch}/sage_setup
|
||||
|
@ -1412,8 +1269,8 @@ chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage-list-packages
|
|||
#------------------------------------------------------------------------
|
||||
|
||||
%if %{with docs}
|
||||
# do not install symlink to '.'
|
||||
rm %{buildroot}%{SAGE_DOC}/output
|
||||
rm %{buildroot}%{SAGE_DOC}/doctrees
|
||||
rm %{buildroot}%{SAGE_DOC}/inventory
|
||||
%endif
|
||||
|
||||
# last install command
|
||||
|
@ -1481,9 +1338,6 @@ exit 0
|
|||
%{SAGE_LOCAL}/bin/QuadraticSieve
|
||||
%{SAGE_LOCAL}/bin/ecm
|
||||
%{SAGE_LOCAL}/bin/gap_stamp
|
||||
%if %{with bundled_pari}
|
||||
%{SAGE_LOCAL}/bin/gp*
|
||||
%endif
|
||||
%{SAGE_LOCAL}/bin/jmol
|
||||
%if %{with bundled_ipython}
|
||||
%{SAGE_LOCAL}/bin/ip*
|
||||
|
@ -1506,26 +1360,15 @@ exit 0
|
|||
%{_bindir}/sage
|
||||
%{_datadir}/pixmaps/%{name}.png
|
||||
%{_datadir}/applications/%{name}.desktop
|
||||
%if %{with bundled_pari}
|
||||
%{SAGE_ROOT}/lib
|
||||
%{SAGE_LOCAL}/pari.desc
|
||||
%endif
|
||||
%{SAGE_SPKG_INST}
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%files core
|
||||
# GPLv2+
|
||||
%if %{with bundled_cysignals}
|
||||
%{SAGE_LOCAL}/bin/cysignals*
|
||||
%endif
|
||||
%{python_sitearch}/sage
|
||||
%if %{without install_hack}
|
||||
%{python_sitearch}/sage-*.egg-info
|
||||
%endif
|
||||
%if %{with bundled_cysignals}
|
||||
%{python_sitearch}/cysignals
|
||||
%{python_sitearch}/cysignals-*.egg-info
|
||||
%endif
|
||||
%if %{with bundled_ipython}
|
||||
%{SAGE_PYTHONPATH}/IPython
|
||||
%endif
|
||||
|
@ -1722,6 +1565,16 @@ exit 0
|
|||
|
||||
########################################################################
|
||||
%changelog
|
||||
* Fri Nov 10 2017 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 8.0-1
|
||||
- Update to sagemath 8.0
|
||||
- Remove cryptominisat build requires
|
||||
- Remove no longer needed -singular patch (upstream updated)
|
||||
- Remove no longer -flask patch (upstream updated)
|
||||
- Remove no longer -pari patch (used now by cypari2)
|
||||
- Disable option to use bundled cysignals
|
||||
- Disable option to use bundled pari
|
||||
- Use system ipython
|
||||
|
||||
* Sat Sep 30 2017 Jerry James <loganjerry@gmail.com> - 7.6-6
|
||||
- Rebuild for arb 2.11.1, eclib 20170815, and libfplll 5.1.0
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue