mirror of
https://src.fedoraproject.org/rpms/sagemath.git
synced 2025-04-22 11:45:56 -04:00
Update to sagemath 8.5.
Also: - Bundle ipython again; Fedora version is too far ahead. Also have to bundle prompt_toolkit since Fedora version is too far ahead of bundled ipython. - Drop LANGUAGES variable setting, now ignored by the sagemath build system. - Drop unused SAGE_CBLAS variable from /usr/bin/sage. - Do not force the C locale when launching sagemath. - Allow the user to override SAGE_DEBUG in /usr/bin/sage. - Add -ecm, -giac, and -latte patches to fix interactions with external tools. - Add -sigfpe patch from upstream.
This commit is contained in:
parent
eaa777c690
commit
55beead27c
31 changed files with 674 additions and 684 deletions
|
@ -4,7 +4,7 @@
|
|||
%global _python_bytecompile_extra 0
|
||||
|
||||
%bcond_with bundled_pexpect
|
||||
%bcond_with bundled_ipython
|
||||
%bcond_without bundled_ipython
|
||||
%bcond_without bundled_ipywidgets
|
||||
%bcond_without bundled_thebe
|
||||
%bcond_without bundled_threejs
|
||||
|
@ -45,6 +45,7 @@
|
|||
%global graphs_pkg graphs-20161026
|
||||
%if %{with bundled_ipython}
|
||||
%global ipython_pkg ipython-5.8.0
|
||||
%global prompt_tookit_pkg prompt_toolkit-1.0.15
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
%global ipywidgets_pkg ipywidgets-7.2.0
|
||||
|
@ -54,7 +55,7 @@
|
|||
%endif
|
||||
%global polytopes_db_pkg polytopes_db-20170220
|
||||
%global rubiks_pkg rubiks-20070912
|
||||
%global sagenb_pkg sagenb-1.0.3
|
||||
%global sagenb_pkg sagenb-1.1.1
|
||||
%global sagenb_export_pkg sagenb_export-3.2
|
||||
%global sagetex_pkg sagetex-3.0
|
||||
%global Sphinx_pkg Sphinx-1.7.6
|
||||
|
@ -72,7 +73,7 @@
|
|||
# Spkg equivalents of required rpms; we pretend they are installed as spkgs.
|
||||
# The version numbers shown are those of the latest released spkg, if the Fedora
|
||||
# version is not behind.
|
||||
%global SAGE_REQUIRED_PKGS 4ti2-1.6.7 cbc-2.9.4 CoCoALib-0.99564 cryptominisat-5.0.1 gap_packages-4.8.6new2 gmp-6.1.2 gmpy2-2.1.0a1 lrslib-062+autotools-2017-03-03 qepcad-B.1.71 saclib-2.2.7 sirocco-2.0 surf-1.0.6-gcc6
|
||||
%global SAGE_REQUIRED_PKGS 4ti2-1.6.7 cbc-2.9.4 CoCoALib-0.99564 cryptominisat-5.0.1 gap_packages-4.8.6new2.p0 gmp-6.1.2 gmpy2-2.1.0a4.p0 lrslib-062+autotools-2017-03-03 qepcad-B.1.71 saclib-2.2.7 sirocco-2.0 surf-1.0.6-gcc6
|
||||
|
||||
%global SAGE_ROOT %{_libdir}/sagemath
|
||||
%global SAGE_LOCAL %{SAGE_ROOT}/local
|
||||
|
@ -85,7 +86,7 @@
|
|||
|
||||
Name: sagemath
|
||||
Summary: A free open-source mathematics software system
|
||||
Version: 8.4
|
||||
Version: 8.5
|
||||
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
|
||||
|
@ -97,6 +98,12 @@ Source1: gprc.expect
|
|||
# Follow maxima's ExclusiveArch
|
||||
ExclusiveArch: aarch64 %{arm} %{ix86} x86_64 ppc sparcv9
|
||||
|
||||
# Fix ecm interact() command
|
||||
Patch0: %{name}-ecm.patch
|
||||
|
||||
# Adapt a giac doctest to recent versions of giac
|
||||
Patch1: %{name}-giac.patch
|
||||
|
||||
# Set of patches to work with system wide packages
|
||||
Patch2: %{name}-scripts.patch
|
||||
|
||||
|
@ -148,7 +155,6 @@ Patch13: %{name}-nauty.patch
|
|||
# remove the buildroot path from Cython output
|
||||
Patch14: %{name}-buildroot.patch
|
||||
|
||||
# correct path to Lfunction include
|
||||
# update c++ standard to fix FTBFS
|
||||
Patch15: %{name}-lcalc.patch
|
||||
|
||||
|
@ -186,7 +192,11 @@ Patch25: %{name}-includes.patch
|
|||
# Use openblas
|
||||
Patch26: %{name}-openblas.patch
|
||||
|
||||
BuildRequires: gdb
|
||||
# Fix paths to latte-integrale binaries
|
||||
Patch27: %{name}-latte.patch
|
||||
|
||||
# Upstream fixes for random SIGFPEs due to ecl messing with the fp state
|
||||
Patch28: %{name}-sigfpe.patch
|
||||
|
||||
BuildRequires: 4ti2
|
||||
BuildRequires: arb-devel
|
||||
|
@ -217,6 +227,7 @@ BuildRequires: gap-pkg-toric
|
|||
BuildRequires: gc-devel
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gd-devel
|
||||
BuildRequires: gdb
|
||||
BuildRequires: gfan
|
||||
BuildRequires: giac-devel
|
||||
BuildRequires: glpk-devel
|
||||
|
@ -297,7 +308,6 @@ BuildRequires: python3dist(pexpect)
|
|||
%endif
|
||||
BuildRequires: python3dist(pickleshare)
|
||||
BuildRequires: python3dist(pip)
|
||||
BuildRequires: python3dist(prompt-toolkit)
|
||||
BuildRequires: python3dist(pkgconfig)
|
||||
BuildRequires: python3dist(psutil)
|
||||
BuildRequires: python3dist(ptyprocess)
|
||||
|
@ -398,7 +408,7 @@ Requires: python3dist(matplotlib)
|
|||
Requires: python3dist(networkx)
|
||||
Requires: python3dist(notebook)
|
||||
%if %{with bundled_ipython}
|
||||
Requires: python3dist(path)
|
||||
Requires: python3dist(path.py)
|
||||
%endif
|
||||
Requires: python3dist(pathlib2)
|
||||
%if %{without bundled_pexpect}
|
||||
|
@ -406,7 +416,6 @@ Requires: python3dist(pexpect)
|
|||
%endif
|
||||
Requires: python3dist(pickleshare)
|
||||
Requires: python3dist(pillow)
|
||||
Requires: python3dist(prompt-toolkit)
|
||||
Requires: python3dist(psutil)
|
||||
Requires: python3dist(ptyprocess)
|
||||
Requires: python3dist(pycryptosat)
|
||||
|
@ -422,7 +431,7 @@ Requires: python3dist(sphinx)
|
|||
Requires: python3dist(sympy)
|
||||
Requires: python3dist(twisted)
|
||||
%if %{with bundled_ipython}
|
||||
Requires: python3dist(zmq)
|
||||
Requires: python3dist(pyzmq)
|
||||
%endif
|
||||
Requires: python3dist(zodb3)
|
||||
Requires: qepcad-B
|
||||
|
@ -461,6 +470,7 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
|
|||
Obsoletes: %{name}-devel < 6.8-1
|
||||
%if %{with bundled_ipython}
|
||||
Provides: bundled(ipython) = %(cut -d- -f2- <<< %{ipython_pkg})
|
||||
Provides: bundled(prompt_toolkit) = %(cut -d- -f2- <<< %{prompt_tookit_pkg})
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
Provides: bundled(ipywidgets) = %(cut -d- -f2- <<< %{ipywidgets_pkg})
|
||||
|
@ -733,6 +743,11 @@ pushd build/pkgs/ipython
|
|||
tar zxf ../../../upstream/%{ipython_pkg}.tar.gz
|
||||
mv %{ipython_pkg} src
|
||||
popd
|
||||
|
||||
pushd build/pkgs/prompt_toolkit
|
||||
tar zxf ../../../upstream/%{prompt_tookit_pkg}.tar.gz
|
||||
mv %{prompt_tookit_pkg} src
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_ipywidgets}
|
||||
|
@ -823,6 +838,8 @@ pushd build/pkgs/widgetsnbextension
|
|||
popd
|
||||
%endif
|
||||
|
||||
%patch0
|
||||
%patch1
|
||||
%patch2
|
||||
%patch3
|
||||
%patch4
|
||||
|
@ -853,6 +870,8 @@ popd
|
|||
%patch24
|
||||
%patch25
|
||||
%patch26
|
||||
%patch27
|
||||
%patch28
|
||||
|
||||
sed -e 's|@@SAGE_ROOT@@|%{SAGE_ROOT}|' \
|
||||
-e 's|@@SAGE_DOC@@|%{SAGE_DOC}|' \
|
||||
|
@ -888,6 +907,7 @@ grep -FrlZ '#!%{_bindir}/env python' | \
|
|||
xargs -0 sed -i 's,#!%{_bindir}/env python,#!%{__python3},'
|
||||
grep -FrlZ '#!%{_bindir}/env sage-python23' | \
|
||||
xargs -0 sed -i 's,#!%{_bindir}/env sage-python23,#!%{__python3},'
|
||||
grep -FrlZ 'sage-python23' | xargs -0 sed -i 's,sage-python23,#!%{__python3},'
|
||||
grep -FrlZ '#!%{_bindir}/env' | \
|
||||
xargs -0 sed -i 's,#!%{_bindir}/env ,#!%{_bindir}/,'
|
||||
grep -rlZ '#!%{_bindir}/python$' | xargs -0 sed -i 's,#!%{_bindir}/python$,&3,'
|
||||
|
@ -956,6 +976,11 @@ pushd build/pkgs/ipython/src
|
|||
%__python3 setup.py build
|
||||
%__python3 setup.py install --root %{_builddir}
|
||||
popd
|
||||
|
||||
pushd build/pkgs/prompt_toolkit/src
|
||||
%__python3 setup.py build
|
||||
%__python3 setup.py install --root %{_builddir}
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_ipywidgets}
|
||||
|
@ -1065,8 +1090,8 @@ pushd src/ext
|
|||
if [ $COUNT -gt 0 ]; then
|
||||
cp -far $dir $SAGE_ETC
|
||||
fi
|
||||
cp -far pari $SAGE_ETC
|
||||
done
|
||||
cp -far pari $SAGE_ETC
|
||||
cp -fa %{SOURCE1} $SAGE_ETC
|
||||
popd
|
||||
|
||||
|
@ -1236,6 +1261,7 @@ popd
|
|||
#------------------------------------------------------------------------
|
||||
%if %{with bundled_ipython}
|
||||
mv %{_builddir}%{python3_sitelib}/IPython %{buildroot}%{SAGE_PYTHONPATH}
|
||||
mv %{_builddir}%{python3_sitelib}/prompt_toolkit %{buildroot}%{SAGE_PYTHONPATH}
|
||||
mv %{_builddir}%{_bindir}/ip* %{buildroot}%{SAGE_LOCAL}/bin
|
||||
%endif
|
||||
|
||||
|
@ -1271,7 +1297,7 @@ popd
|
|||
cat > %{buildroot}%{_bindir}/sage << EOF
|
||||
#!/bin/bash -i
|
||||
|
||||
export CUR=\`pwd\`
|
||||
export CUR=\$PWD
|
||||
##export DOT_SAGE="\$HOME/.sage"
|
||||
mkdir -p \$DOT_SAGE/{maxima,sympow,tmp}
|
||||
export SAGE_TESTDIR=\$DOT_SAGE/tmp
|
||||
|
@ -1283,7 +1309,7 @@ export SAGE_ETC="$SAGE_ETC"
|
|||
export SAGE_SRC="%{buildroot}%{SAGE_SRC}"
|
||||
##export SAGE_DOC="$SAGE_DOC"
|
||||
##export SAGE_DOC_SRC="\$SAGE_DOC"
|
||||
##export SAGE_PKGS="\$SAGE_LOCAL//var/lib/sage/installed"
|
||||
##export SAGE_PKGS="\$SAGE_LOCAL/var/lib/sage/installed"
|
||||
module load 4ti2-%{_arch}
|
||||
module load lrcalc-%{_arch}
|
||||
module load surf-geometry-%{_arch}
|
||||
|
@ -1292,14 +1318,13 @@ export SINGULAR_DATA_DIR=%{_datadir}
|
|||
export SINGULAR_BIN_DIR=%{_libdir}/Singular
|
||||
export SINGULAR_SO=%{_libdir}/libSingular-4.1.1.so
|
||||
##export PYTHONPATH="$SAGE_PYTHONPATH:\$SAGE_LOCAL/bin"
|
||||
export SAGE_CBLAS=blas
|
||||
export SAGE_FORTRAN=%{_bindir}/gfortran
|
||||
export SAGE_FORTRAN_LIB=\`gfortran --print-file-name=libgfortran.so\`
|
||||
export SYMPOW_DIR="\$DOT_SAGE/sympow"
|
||||
export LC_ALL=C.UTF-8
|
||||
export LD_LIBRARY_PATH=\$SAGE_ROOT/lib:\$LD_LIBRARY_PATH
|
||||
# Required for sage -gdb
|
||||
export SAGE_DEBUG=no
|
||||
: \${SAGE_DEBUG:=no}
|
||||
export SAGE_DEBUG
|
||||
$SAGE_LOCAL/bin/sage "\$@"
|
||||
EOF
|
||||
#------------------------------------------------------------------------
|
||||
|
@ -1357,7 +1382,7 @@ pushd src/doc
|
|||
export SAGE_DOC_SRC=$SAGE_DOC
|
||||
# python -m sage_setup.docbuild
|
||||
# Build with an X server running, required by some doc builders
|
||||
SAGE_NUM_THREADS=2 LANGUAGES="ca de en fr hu it ja pt ru tr" \
|
||||
SAGE_NUM_THREADS=2 \
|
||||
xvfb-run -a -n 1 %__python3 -m docbuild --no-pdf-links -k all html -j
|
||||
rm -f %{buildroot}%{SAGE_SRC}/doc
|
||||
ln -sf %{SAGE_DOC} %{buildroot}%{SAGE_SRC}/doc
|
||||
|
@ -1518,9 +1543,6 @@ chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage-list-packages
|
|||
# last install command
|
||||
rm -fr $DOT_SAGE
|
||||
|
||||
########################################################################
|
||||
%ldconfig_scriptlets core
|
||||
|
||||
########################################################################
|
||||
%files
|
||||
# GPLv2+
|
||||
|
@ -1573,6 +1595,7 @@ rm -fr $DOT_SAGE
|
|||
%endif
|
||||
%if %{with bundled_ipython}
|
||||
%{SAGE_PYTHONPATH}/IPython
|
||||
%{SAGE_PYTHONPATH}/prompt_toolkit
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
%{SAGE_PYTHONPATH}/ipywidgets
|
||||
|
@ -1793,6 +1816,17 @@ rm -fr $DOT_SAGE
|
|||
|
||||
########################################################################
|
||||
%changelog
|
||||
* Thu Jan 17 2019 Jerry James <loganjerry@gmail.com> - 8.5-1
|
||||
- Update to sagemath 8.5
|
||||
- Bundle ipython again; Fedora version is too far ahead. Also have to bundle
|
||||
prompt_toolkit since Fedora version is too far ahead of bundled ipython.
|
||||
- Drop LANGUAGES variable setting, now ignored by the sagemath build system
|
||||
- Drop unused SAGE_CBLAS variable from /usr/bin/sage
|
||||
- Do not force the C locale when launching sagemath
|
||||
- Allow the user to override SAGE_DEBUG in /usr/bin/sage
|
||||
- Add -ecm, -giac, and -latte patches to fix interactions with external tools
|
||||
- Add -sigfpe patch from upstream
|
||||
|
||||
* Thu Oct 25 2018 Jerry James <loganjerry@gmail.com> - 8.4-1
|
||||
- Update to sagemath 8.4
|
||||
- Build for python 3 instead of python 2 due to upcoming python 2 removal
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue