mirror of
https://src.fedoraproject.org/rpms/sagemath.git
synced 2025-04-22 11:45:56 -04:00
Version 9.4.
- Drop upstreamed -eclib patch. - Drop unnecessary -readonly patch. - Unbundle ipywidgets. - Bundle memory_allocator for now.
This commit is contained in:
parent
db8b5a20c1
commit
916819fe9b
11 changed files with 390 additions and 482 deletions
134
sagemath.spec
134
sagemath.spec
|
@ -5,8 +5,8 @@
|
|||
|
||||
%bcond_with bundled_pexpect
|
||||
%bcond_with bundled_ipython
|
||||
%bcond_without bundled_ipywidgets
|
||||
%bcond_without bundled_jupyter_jsmol
|
||||
%bcond_without bundled_memory_allocator
|
||||
%bcond_without bundled_thebe
|
||||
%bcond_without bundled_threejs
|
||||
%bcond_without install_hack
|
||||
|
@ -19,7 +19,7 @@
|
|||
%endif
|
||||
|
||||
# use a workaround to match upstream sagemath patched sphinx
|
||||
%bcond_without sphinx_hack
|
||||
%bcond_with sphinx_hack
|
||||
|
||||
# use workaround to match upstream sagemath patched cython
|
||||
%bcond_with cython_hack
|
||||
|
@ -41,26 +41,26 @@
|
|||
%global elliptic_curves_pkg elliptic_curves-0.8.1
|
||||
%global graphs_pkg graphs-20210214
|
||||
%if %{with bundled_ipython}
|
||||
%global ipython_ver 7.13.0
|
||||
%global ipython_ver 7.16.1
|
||||
%global ipython_pkg ipython-%{ipython_ver}
|
||||
%global prompt_toolkit_ver 3.0.5
|
||||
%global prompt_tookit_pkg prompt_toolkit-%{prompt_toolkit_ver}
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
%global ipywidgets_ver 7.6.3
|
||||
%global ipywidgets_pkg ipywidgets-%{ipywidgets_ver}
|
||||
%endif
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
%global jupyter_jsmol_ver 0.2.4
|
||||
%global jupyter_jsmol_pkg jupyter_jsmol-%{jupyter_jsmol_ver}
|
||||
%endif
|
||||
%if %{with bundled_memory_allocator}
|
||||
%global memory_allocator_ver 0.1.0
|
||||
%global memory_allocator_pkg memory_allocator-%{memory_allocator_ver}
|
||||
%endif
|
||||
%if %{with bundled_pexpect}
|
||||
%global pexpect_pkg pexpect-4.8.0
|
||||
%endif
|
||||
%global polytopes_db_pkg polytopes_db-20170220
|
||||
%global sagetex_pkg sagetex-3.5
|
||||
%global Sphinx_pkg Sphinx-3.1.2
|
||||
%global singular_pkg singular-4.2.0p2
|
||||
%global Sphinx_pkg Sphinx-4.0.1
|
||||
%global singular_pkg singular-4.2.0p3
|
||||
%if %{with bundled_thebe}
|
||||
%global thebe_ver 9624e0a0
|
||||
%global thebe_pkg thebe-%{thebe_ver}
|
||||
|
@ -71,7 +71,7 @@
|
|||
%endif
|
||||
|
||||
# Spkg equivalents of required rpms; we pretend they are installed as spkgs.
|
||||
%global SAGE_REQUIRED_PKGS 4ti2-1.6.9 bliss-0.73 CoCoALib-0.99712 coxeter3-3.1 cryptominisat-5.8.0 database_cremona_ellcurve-%{cremona_ver} gap_packages-4.11.0 libsirocco-2.0.2 lrslib-071a mcqd-1.0 meataxe-1.0 primecount-7.0 qepcad-B.1.74 saclib-2.2.8 surf-1.0.6-gcc6 tdlib-0.9.0
|
||||
%global SAGE_REQUIRED_PKGS 4ti2-1.6.9 bliss-0.73 CoCoALib-0.99713 coxeter3-3.1 cryptominisat-5.8.0 database_cremona_ellcurve-%{cremona_ver} gap_packages-4.11.1 libsirocco-2.1.0 lrslib-071b mcqd-1.0 meataxe-1.0 primecount-7.1 qepcad-B.1.74 saclib-2.2.8 surf-1.0.6-gcc6 tdlib-0.9.1
|
||||
|
||||
%ifarch %{ix86} x86_64
|
||||
%global SAGE_REQUIRED_PKGS %{SAGE_REQUIRED_PKGS} fes-0.2
|
||||
|
@ -88,8 +88,8 @@
|
|||
|
||||
Name: sagemath
|
||||
Summary: A free open-source mathematics software system
|
||||
Version: 9.3
|
||||
Release: 5%{?dist}
|
||||
Version: 9.4
|
||||
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
|
||||
|
@ -127,9 +127,6 @@ Patch4: %{name}-rpmbuild.patch
|
|||
# build documentation in buildroot environment
|
||||
Patch5: %{name}-sagedoc.patch
|
||||
|
||||
# do not attempt to create state files in system directories
|
||||
Patch6: %{name}-readonly.patch
|
||||
|
||||
# work with all maxima-runtime lisp backend packages
|
||||
Patch7: %{name}-maxima.patch
|
||||
|
||||
|
@ -188,9 +185,6 @@ Patch23: %{name}-intersphinx.patch
|
|||
# Remove an unused call to a primecount function that no longer exists
|
||||
Patch24: %{name}-primecount.patch
|
||||
|
||||
# Adapt to recent changes in eclib
|
||||
Patch25: %{name}-eclib.patch
|
||||
|
||||
BuildRequires: 4ti2
|
||||
BuildRequires: appstream
|
||||
BuildRequires: arb-devel
|
||||
|
@ -198,6 +192,7 @@ BuildRequires: bc
|
|||
BuildRequires: bliss-devel
|
||||
BuildRequires: boost-devel
|
||||
BuildRequires: brial-devel
|
||||
BuildRequires: chrpath
|
||||
BuildRequires: cmake
|
||||
BuildRequires: cddlib-devel
|
||||
BuildRequires: cddlib-tools
|
||||
|
@ -331,7 +326,6 @@ BuildRequires: pkgconfig(openssl)
|
|||
BuildRequires: pkgconfig(pynac)
|
||||
BuildRequires: pkgconfig(readline)
|
||||
BuildRequires: pkgconfig(Singular)
|
||||
BuildRequires: pkgconfig(sqlite3)
|
||||
BuildRequires: pkgconfig(tk)
|
||||
BuildRequires: pkgconfig(zlib)
|
||||
BuildRequires: planarity-devel
|
||||
|
@ -366,6 +360,7 @@ BuildRequires: %{py3_dist ipykernel}
|
|||
%if %{without bundled_ipython}
|
||||
BuildRequires: %{py3_dist ipython}
|
||||
%endif
|
||||
BuildRequires: %{py3_dist ipywidgets}
|
||||
%if %{with bundled_ipython}
|
||||
BuildRequires: %{py3_dist jedi}
|
||||
%endif
|
||||
|
@ -385,8 +380,10 @@ BuildRequires: %{py3_dist pickleshare}
|
|||
%endif
|
||||
BuildRequires: %{py3_dist pip}
|
||||
BuildRequires: %{py3_dist pkgconfig}
|
||||
BuildRequires: %{py3_dist pluggy}
|
||||
BuildRequires: %{py3_dist psutil}
|
||||
BuildRequires: %{py3_dist ptyprocess}
|
||||
BuildRequires: %{py3_dist py}
|
||||
BuildRequires: %{py3_dist pycryptosat}
|
||||
BuildRequires: %{py3_dist pyopenssl}
|
||||
%if %{with bundled_ipython}
|
||||
|
@ -403,7 +400,9 @@ BuildRequires: %{py3_dist simplegeneric}
|
|||
BuildRequires: %{py3_dist six}
|
||||
BuildRequires: %{py3_dist sphinx}
|
||||
BuildRequires: %{py3_dist sympy}
|
||||
BuildRequires: %{py3_dist toml}
|
||||
BuildRequires: %{py3_dist tox}
|
||||
BuildRequires: %{py3_dist typing-extensions}
|
||||
BuildRequires: %{py3_dist wheel}
|
||||
BuildRequires: %{py3_dist widgetsnbextension}
|
||||
BuildRequires: %{py3_dist zodb3}
|
||||
|
@ -542,6 +541,7 @@ Requires: %{py3_dist ipykernel}
|
|||
%if %{without bundled_ipython}
|
||||
Requires: %{py3_dist ipython}
|
||||
%endif
|
||||
Requires: %{py3_dist ipywidgets}
|
||||
%if %{with bundled_ipython}
|
||||
Requires: %{py3_dist jedi}
|
||||
%endif
|
||||
|
@ -581,12 +581,12 @@ Requires: texlive
|
|||
Provides: bundled(ipython) = %{ipython_ver}
|
||||
Provides: bundled(prompt_toolkit) = %{prompt_toolkit_ver}
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
Provides: bundled(ipywidgets) = %{ipywidgets_ver}
|
||||
%endif
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
Provides: bundled(jupyter-jsmol) = %{jupyter_jsmol_ver}
|
||||
%endif
|
||||
%if %{with bundled_memory_allocator}
|
||||
Provides: bundled(memory-allocator) = %{memory_allocator_ver}
|
||||
%endif
|
||||
|
||||
%description core
|
||||
This package contains the core sagemath python modules.
|
||||
|
@ -841,13 +841,6 @@ pushd build/pkgs/prompt_toolkit
|
|||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_ipywidgets}
|
||||
pushd build/pkgs/ipywidgets
|
||||
tar zxf ../../../upstream/%{ipywidgets_pkg}.tar.gz
|
||||
mv %{ipywidgets_pkg} src
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
pushd build/pkgs/jupyter_jsmol
|
||||
tar zxf ../../../upstream/%{jupyter_jsmol_pkg}.tar.gz
|
||||
|
@ -855,6 +848,13 @@ pushd build/pkgs/jupyter_jsmol
|
|||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_memory_allocator}
|
||||
pushd build/pkgs/memory_allocator
|
||||
tar zxf ../../../upstream/%{memory_allocator_pkg}.tar.gz
|
||||
mv %{memory_allocator_pkg} src
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_pexpect}
|
||||
pushd build/pkgs/pexpect
|
||||
tar zxf ../../../upstream/%{pexpect_pkg}.tar.gz
|
||||
|
@ -898,9 +898,8 @@ popd
|
|||
|
||||
%if %{with bundled_threejs}
|
||||
pushd build/pkgs/threejs
|
||||
mkdir src
|
||||
cd src
|
||||
tar zxf ../../../../upstream/%{threejs_pkg}.tar.gz
|
||||
tar zxf ../../../upstream/%{threejs_pkg}.tar.gz
|
||||
mv %{threejs_pkg} src
|
||||
popd
|
||||
%endif
|
||||
|
||||
|
@ -910,7 +909,6 @@ popd
|
|||
%patch3
|
||||
%patch4
|
||||
%patch5
|
||||
%patch6
|
||||
%patch7
|
||||
%patch8
|
||||
%patch9
|
||||
|
@ -932,11 +930,8 @@ popd
|
|||
%patch22
|
||||
%patch23
|
||||
%patch24
|
||||
%patch25
|
||||
|
||||
sed -e 's|@@SAGE_ROOT@@|%{SAGE_ROOT}|' \
|
||||
-e 's|@@SAGE_DOC@@|%{SAGE_DOC}|' \
|
||||
-e 's|@@SAGE_LOCAL@@|%{SAGE_LOCAL}|' \
|
||||
sed -e 's|@@SAGE_LOCAL@@|%{SAGE_LOCAL}|' \
|
||||
-e 's|@@LIBDIR@@|%{_libdir}|g' \
|
||||
-i src/sage/env.py
|
||||
|
||||
|
@ -975,7 +970,6 @@ sed -i 's,%{_bindir}/python,&3,' src/sage/misc/dev_tools.py
|
|||
sed -e 's,local/bin/python,bin/python,' \
|
||||
-e 's,#!%{_bindir}/python,&3,' \
|
||||
-i src/sage/repl/preparse.py
|
||||
sed -i 's,$SAGE_LOCAL/bin/python,%{_bindir}/python,g' src/bin/sage
|
||||
%if %{with bundled_ipython}
|
||||
sed -e "s|'%{_bindir}/env', 'which'|'%{_bindir}/which'|" \
|
||||
-i build/pkgs/ipython/src/IPython/utils/_process_posix.py
|
||||
|
@ -993,20 +987,6 @@ sed -i 's/yum/rpm/' build/bin/sage-guess-package-system
|
|||
# Allow use of python 3.10
|
||||
sed -i 's/3\.10\.0/3.11.0/g' configure
|
||||
|
||||
# Allow use of GCC 11
|
||||
sed -i 's/1\[1-9\]/1[2-9]/' configure
|
||||
|
||||
# Allow use of pari 2.13.1
|
||||
sed -e 's/Mod(0, 2)/0/' \
|
||||
-e 's,share/doc/pari/pari\.cfg,%{_lib}/pari/pari.cfg,' \
|
||||
-i configure
|
||||
|
||||
# Allow use of fplll 5.4.1
|
||||
sed -i 's/5\.4\.0/5.4.1/g' configure
|
||||
|
||||
# Allow use of giac 1.7
|
||||
sed -i 's/1\.6\.999/1.7.999/g' configure
|
||||
|
||||
# Do not build with -march=native
|
||||
sed -i 's/CFLAGS_MARCH="-march=native"/CFLAGS_MARCH=""/' configure
|
||||
|
||||
|
@ -1044,13 +1024,14 @@ ln -sf %{_datadir} $SAGE_LOCAL/share
|
|||
|
||||
export PATH=%{buildroot}%{_bindir}:$PATH
|
||||
export PYTHON=%{_bindir}/python3
|
||||
export PYTHONPATH=%{buildroot}%{python3_sitearch}:$PYTHONPATH
|
||||
export PYTHONPATH=%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}:$PYTHONPATH
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Run the configure script to generate files
|
||||
export GSL_LIBS="-lgsl -lflexiblas -lm"
|
||||
%configure \
|
||||
--prefix=$SAGE_LOCAL \
|
||||
--disable-rpath \
|
||||
--disable-silent-rules \
|
||||
--enable-4ti2 \
|
||||
--enable-bliss \
|
||||
|
@ -1091,15 +1072,15 @@ pushd build/pkgs/prompt_toolkit/src
|
|||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_ipywidgets}
|
||||
pushd build/pkgs/ipywidgets/src
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
pushd build/pkgs/jupyter_jsmol/src
|
||||
%{python3} setup.py build
|
||||
%{python3} setup.py install --root %{_builddir}
|
||||
popd
|
||||
%endif
|
||||
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
pushd build/pkgs/jupyter_jsmol/src
|
||||
%if %{with bundled_memory_allocator}
|
||||
pushd build/pkgs/memory_allocator/src
|
||||
%{python3} setup.py build
|
||||
%{python3} setup.py install --root %{_builddir}
|
||||
popd
|
||||
|
@ -1119,6 +1100,7 @@ popd
|
|||
# Restore environment used to generate bundled interfaces
|
||||
export PATH=$save_PATH
|
||||
export SAGE_LOCAL=$save_LOCAL
|
||||
export PYTHONPATH=$PYTHONPATH:%{_builddir}%{python3_sitelib}:%{_builddir}%{python3_sitearch}
|
||||
mkdir -p %{buildroot}%{SAGE_SPKG_INST}
|
||||
mkdir -p %{buildroot}%{_libdir}/sagemath/build/pkgs
|
||||
|
||||
|
@ -1158,8 +1140,8 @@ mkdir -p $DOT_SAGE/tmp
|
|||
|
||||
export PATH=%{buildroot}%{_bindir}:$PATH
|
||||
export PYTHON=%{_bindir}/python3
|
||||
export PYTHONPATH=%{buildroot}%{python3_sitearch}:$PYTHONPATH
|
||||
export PYTHONPATH=%{_builddir}%{python3_sitearch}:$PYTHONPATH
|
||||
export PYTHONPATH=%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}:$PYTHONPATH
|
||||
export PYTHONPATH=%{_builddir}%{python3_sitearch}:%{_builddir}%{python3_sitelib}:$PYTHONPATH
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
mkdir -p %{buildroot}%{_bindir}
|
||||
|
@ -1315,13 +1297,13 @@ mv %{_builddir}%{_bindir}/ip* %{buildroot}%{SAGE_LOCAL}/bin
|
|||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%if %{with bundled_ipywidgets}
|
||||
mv %{_builddir}%{python3_sitelib}/ipywidgets* %{buildroot}%{SAGE_PYTHONPATH}
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
mv %{_builddir}%{python3_sitelib}/jupyter_jsmol* %{buildroot}%{SAGE_PYTHONPATH}
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
mv %{_builddir}%{python3_sitelib}/jupyter_jsmol* %{buildroot}%{SAGE_PYTHONPATH}
|
||||
%if %{with bundled_memory_allocator}
|
||||
mv %{_builddir}%{python3_sitearch}/memory_allocator* %{buildroot}%{SAGE_PYTHONPATH}
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
|
@ -1408,7 +1390,7 @@ pushd src/doc
|
|||
export PATH=%{buildroot}%{_bindir}:$SAGE_LOCAL/bin:$PATH
|
||||
export SINGULARPATH=%{_datadir}/singular/LIB
|
||||
export SINGULAR_BIN_DIR=%{_libdir}/Singular
|
||||
export PYTHONPATH=$SAGE_SETUP:%{buildroot}%{python3_sitearch}:$SAGE_PYTHONPATH:$SAGE_SRC
|
||||
export PYTHONPATH=$SAGE_SETUP:%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}:$SAGE_PYTHONPATH:$SAGE_SRC
|
||||
|
||||
%if %{with sphinx_hack}
|
||||
pushd ../../build/pkgs/sphinx/src
|
||||
|
@ -1458,6 +1440,13 @@ perl -pi -e 's|%{buildroot}||g;' \
|
|||
# with docs
|
||||
%endif
|
||||
|
||||
# Even more wrong buildroot references
|
||||
for shared in $(find %{buildroot}%{python3_sitearch} -name \*.so); do
|
||||
if chrpath -l $shared | grep -Fq BUILDROOT; then
|
||||
chrpath -r %{SAGE_LOCAL}/lib $shared
|
||||
fi
|
||||
done
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
# Fix links
|
||||
export SAGE_SRC=%{buildroot}%{SAGE_SRC}
|
||||
|
@ -1617,7 +1606,7 @@ popd
|
|||
#------------------------------------------------------------------------
|
||||
# Build the large Cremona database
|
||||
export PATH=%{buildroot}%{SAGE_LOCAL}/bin:$PATH
|
||||
export PYTHONPATH=%{buildroot}%{SAGE_PYTHONPATH}:%{buildroot}%{python3_sitearch}
|
||||
export PYTHONPATH=%{buildroot}%{SAGE_PYTHONPATH}:%{buildroot}%{python3_sitearch}:%{buildroot}%{python3_sitelib}
|
||||
touch %{buildroot}%{SAGE_SHARE}/cremona/cremona.db
|
||||
cat > cremona.sage << EOF
|
||||
import sage.env
|
||||
|
@ -1784,12 +1773,12 @@ end
|
|||
%{SAGE_PYTHONPATH}/IPython
|
||||
%{SAGE_PYTHONPATH}/prompt_toolkit*
|
||||
%endif
|
||||
%if %{with bundled_ipywidgets}
|
||||
%{SAGE_PYTHONPATH}/ipywidgets*
|
||||
%endif
|
||||
%if %{with bundled_jupyter_jsmol}
|
||||
%{SAGE_PYTHONPATH}/jupyter_jsmol*
|
||||
%endif
|
||||
%if %{with bundled_memory_allocator}
|
||||
%{SAGE_PYTHONPATH}/memory_allocator*
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%files data
|
||||
|
@ -1985,7 +1974,7 @@ end
|
|||
%{SAGE_ETC}/notebook-ipython/
|
||||
# LGPLv2+
|
||||
%{_datadir}/jupyter/kernels/sagemath/
|
||||
%{_datadir}/jupyter/nbextensions/threejs
|
||||
%{_datadir}/jupyter/nbextensions/threejs-sage
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%files sagetex
|
||||
|
@ -1997,6 +1986,13 @@ end
|
|||
|
||||
########################################################################
|
||||
%changelog
|
||||
* Fri Aug 27 2021 Jerry James <loganjerry@gmail.com> - 9.4-1
|
||||
- Version 9.4
|
||||
- Drop upstreamed -eclib patch
|
||||
- Drop unnecessary -readonly patch
|
||||
- Unbundle ipywidgets
|
||||
- Bundle memory_allocator for now
|
||||
|
||||
* Wed Aug 18 2021 Jerry James <loganjerry@gmail.com> - 9.3-5
|
||||
- Unbundle flintqs
|
||||
- Require gp2c and pari-nftables
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue