mirror of
https://src.fedoraproject.org/rpms/sagemath.git
synced 2025-04-22 11:45:56 -04:00
Update to sagemath 6.8
This commit is contained in:
parent
b4699213da
commit
3aa9b0c734
32 changed files with 806 additions and 615 deletions
307
sagemath.spec
307
sagemath.spec
|
@ -1,5 +1,7 @@
|
|||
%global __provides_exclude_from .*/site-packages/.*\\.so
|
||||
|
||||
%bcond_without bundled_pari
|
||||
|
||||
# for faster full rpm test builds
|
||||
%bcond_without docs
|
||||
|
||||
|
@ -21,9 +23,12 @@
|
|||
%global SAGE_TIMEOUT_LONG 180
|
||||
|
||||
%global conway_polynomials_pkg conway_polynomials-0.4
|
||||
%global elliptic_curves_pkg elliptic_curves-0.7
|
||||
%global elliptic_curves_pkg elliptic_curves-0.8
|
||||
%global flintqs_pkg flintqs-20070817
|
||||
%global graphs_pkg graphs-20130920
|
||||
%if %{with bundled_pari}
|
||||
%global pari_pkg pari-2.8-1637-g489005a
|
||||
%endif
|
||||
%global pexpect_pkg pexpect-2.0
|
||||
%global polytopes_db_pkg polytopes_db-20120220
|
||||
%global rubiks_pkg rubiks-20070912
|
||||
|
@ -37,12 +42,13 @@
|
|||
%global SAGE_SHARE %{_datadir}/sagemath
|
||||
%global SAGE_ETC %{SAGE_SHARE}/etc
|
||||
%global SAGE_PYTHONPATH %{SAGE_ROOT}/site-packages
|
||||
%global SAGE_SPKG_INST %{SAGE_LOCAL}/var/lib/sage/installed
|
||||
|
||||
Name: sagemath
|
||||
Group: Applications/Engineering
|
||||
Summary: A free open-source mathematics software system
|
||||
Version: 6.5
|
||||
Release: 14%{?dist}
|
||||
Version: 6.8
|
||||
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
|
||||
|
@ -52,15 +58,6 @@ Source0: http://boxen.math.washington.edu/home/%{name}/sage-mirror/src/sage-%{ve
|
|||
Source1: gprc.expect
|
||||
Source2: makecmds.sty
|
||||
|
||||
# 1. scons ignores most environment variables
|
||||
# 2. scons 2.2* does not have soname support (expected for scons 2.3*)
|
||||
# This patch adds some regex substition templates for CFLAGS, etc, and
|
||||
# minor adaptation from full scons patch at:
|
||||
# http://scons.tigris.org/nonav/issues/showattachment.cgi/902/soname_func.py
|
||||
# Discussed at:
|
||||
# http://scons.tigris.org/issues/show_bug.cgi?id=2869
|
||||
Patch0: %{name}-scons.patch
|
||||
|
||||
# Upstream uses mpir not gmp, but the rpm package is tailored to use gmp
|
||||
Patch1: %{name}-gmp.patch
|
||||
|
||||
|
@ -123,20 +120,19 @@ Patch15: %{name}-nauty.patch
|
|||
# http://www-gap.mcs.st-and.ac.uk/Packages/hap.html
|
||||
Patch16: %{name}-gap-hap.patch
|
||||
|
||||
# enable lrcalc
|
||||
Patch17: %{name}-lrcalc.patch
|
||||
# correct path to Lfunction include
|
||||
Patch17: %{name}-lcalc.patch
|
||||
|
||||
# enable cbc
|
||||
# avoid assertion in coin backend
|
||||
Patch18: %{name}-cbc.patch
|
||||
|
||||
# Use system gap directories
|
||||
Patch19: %{name}-libgap.patch
|
||||
|
||||
# enable fes
|
||||
Patch20: %{name}-fes.patch
|
||||
|
||||
# enable cryptominisat
|
||||
Patch21: %{name}-cryptominisat.patch
|
||||
# Build fes
|
||||
Patch20: %{name}-fes-build.patch
|
||||
# Disable fes
|
||||
Patch21: %{name}-fes.patch
|
||||
|
||||
# Side effect of using distro packages
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=974769
|
||||
|
@ -145,24 +141,22 @@ Patch22: %{name}-sympy.patch
|
|||
# Fix a name clash with NTL
|
||||
Patch23: %{name}-ntl.patch
|
||||
|
||||
# Temporary patch: http://trac.sagemath.org/ticket/17657
|
||||
Patch24: %{name}-parallel.patch
|
||||
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1194941
|
||||
Patch25: %{name}-ipython3.patch
|
||||
|
||||
# Fix a changed interface in NTL 9.x
|
||||
Patch26: %{name}-ntl9.patch
|
||||
Patch24: %{name}-ntl9.patch
|
||||
|
||||
# Correct unable to start QEPCAD within sage
|
||||
# https://bugzilla.redhat.com/show_bug.cgi?id=1243590
|
||||
Patch27: %{name}-qepcad.patch
|
||||
Patch25: %{name}-qepcad.patch
|
||||
|
||||
# Temporary correction for invalid conversion from
|
||||
# 'int' to 'polybori::COrderEnums::ordercodes'
|
||||
Patch28: %{name}-polybori.patch
|
||||
Patch26: %{name}-polybori.patch
|
||||
|
||||
# Correct path to arb headers
|
||||
Patch27: %{name}-arb.patch
|
||||
|
||||
BuildRequires: 4ti2
|
||||
BuildRequires: arb-devel
|
||||
BuildRequires: atlas-devel
|
||||
BuildRequires: cddlib-tools
|
||||
BuildRequires: cliquer-devel
|
||||
|
@ -209,8 +203,11 @@ BuildRequires: mpfi-devel
|
|||
BuildRequires: ntl-devel
|
||||
BuildRequires: numpy
|
||||
BuildRequires: palp
|
||||
%if %{without bundled_pari}
|
||||
BuildRequires: pari-devel
|
||||
BuildRequires: pari-gp
|
||||
%endif
|
||||
BuildRequires: planarity-devel
|
||||
BuildRequires: ppl-devel
|
||||
BuildRequires: pynac-devel
|
||||
BuildRequires: python2-devel
|
||||
|
@ -229,12 +226,13 @@ BuildRequires: R
|
|||
BuildRequires: ratpoints-devel
|
||||
BuildRequires: readline-devel
|
||||
BuildRequires: rpy
|
||||
BuildRequires: rw-devel
|
||||
BuildRequires: scons
|
||||
BuildRequires: Singular-devel
|
||||
BuildRequires: stix-math-fonts
|
||||
BuildRequires: symmetrica-devel
|
||||
BuildRequires: sympow
|
||||
BuildRequires: sympy
|
||||
BuildRequires: symmetrica-devel
|
||||
BuildRequires: texlive
|
||||
# For _jsdir macro
|
||||
BuildRequires: web-assets-devel
|
||||
|
@ -284,7 +282,9 @@ Requires: R
|
|||
Requires: rpy
|
||||
Requires: %{name}-core
|
||||
Requires: %{name}-data
|
||||
%if %{with docs}
|
||||
Requires: %{name}-doc-en
|
||||
%endif
|
||||
Requires: %{name}-notebook
|
||||
Requires: %{name}-rubiks
|
||||
Requires: %{name}-sagetex
|
||||
|
@ -306,6 +306,7 @@ packages into a common Python-based interface.
|
|||
Summary: Open Source Mathematics Software
|
||||
Group: Applications/Engineering
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
Obsoletes: %{name}-devel < 6.8-1
|
||||
|
||||
%description core
|
||||
This package contains the core sagemath python modules.
|
||||
|
@ -389,16 +390,6 @@ you can use sage.geometry.lattice_polytope module, which relies on PALP for
|
|||
some of its functionality. To get access to the databases of this package, use
|
||||
ReflexivePolytope and ReflexivePolytopes commands.
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%package devel
|
||||
Summary: Development files for %{name}
|
||||
Group: Development/Libraries
|
||||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||||
|
||||
%description devel
|
||||
This package contains the header files and development documentation
|
||||
for %{name}.
|
||||
|
||||
%if %{with docs}
|
||||
#------------------------------------------------------------------------
|
||||
%package doc
|
||||
|
@ -575,6 +566,18 @@ pushd build/pkgs/graphs
|
|||
mv %{graphs_pkg} src
|
||||
popd
|
||||
|
||||
%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
|
||||
popd
|
||||
popd
|
||||
%endif
|
||||
|
||||
pushd build/pkgs/pexpect
|
||||
tar jxf ../../../upstream/%{pexpect_pkg}.tar.bz2
|
||||
mv %{pexpect_pkg} src
|
||||
|
@ -614,7 +617,6 @@ pushd build/pkgs/sagetex
|
|||
mv %{sagetex_pkg} src
|
||||
popd
|
||||
|
||||
%patch0
|
||||
%patch1
|
||||
%patch2
|
||||
%patch3
|
||||
|
@ -622,11 +624,14 @@ popd
|
|||
%patch5
|
||||
%patch6
|
||||
%patch7
|
||||
|
||||
%patch8
|
||||
%patch9
|
||||
%patch10
|
||||
|
||||
%if %{without bundled_pari}
|
||||
%patch11
|
||||
%endif
|
||||
|
||||
%patch12
|
||||
%patch13
|
||||
%patch14
|
||||
|
@ -638,18 +643,16 @@ popd
|
|||
|
||||
%if %{with fes}
|
||||
%patch20
|
||||
%else
|
||||
%patch21
|
||||
%endif
|
||||
|
||||
%patch21
|
||||
%patch22
|
||||
%patch23
|
||||
%patch24
|
||||
%if 0%{fedora} > 22
|
||||
%patch25
|
||||
%endif
|
||||
%patch26
|
||||
%patch27
|
||||
%patch28
|
||||
|
||||
sed -e 's|@@SAGE_ROOT@@|%{SAGE_ROOT}|' \
|
||||
-e 's|@@SAGE_DOC@@|%{SAGE_DOC}|' \
|
||||
|
@ -705,30 +708,52 @@ export PATH=%{buildroot}%{_bindir}:$PATH
|
|||
export PYTHONPATH=%{buildroot}%{python_sitearch}:$PYTHONPATH
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
pushd src/c_lib
|
||||
# scons ignores most environment variables
|
||||
# and does not have soname support
|
||||
ldflags=$(sed 's/[[:blank:]]*$//' <<< "%{__global_ldflags}")
|
||||
sed -e 's|@@includedir@@|%{_includedir}|g' \
|
||||
-e 's|@@libdir@@|%{_libdir}|g' \
|
||||
-e 's|@@optflags@@|%{optflags}|g' \
|
||||
-e "s|@@__global_ldflags@@|$ldflags|g" \
|
||||
-i SConstruct
|
||||
# force building ntl_wrap.cpp with gcc otherwise other
|
||||
# modules will not find mangled symbols.
|
||||
CXX=gcc UNAME=Linux SAGE64=auto scons
|
||||
ln -s libcsage.so.0 libcsage.so
|
||||
popd
|
||||
pushd src/sage/libs/mpmath
|
||||
dos2unix ext_impl.pxd ext_libmp.pyx ext_main.pxd ext_main.pyx
|
||||
# Save and update environment to generate bundled interfaces
|
||||
save_PATH=$PATH
|
||||
save_LOCAL=$SAGE_LOCAL
|
||||
export PATH=%{_builddir}/bin:$PATH
|
||||
export SAGE_LOCAL=%{_builddir}
|
||||
|
||||
%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
|
||||
python ./setup.py build
|
||||
%__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
|
||||
|
||||
# Restore environment used to generate bundled interfaces
|
||||
export PATH=$save_PATH
|
||||
export SAGE_LOCAL=$save_LOCAL
|
||||
|
||||
%if 1
|
||||
pushd src
|
||||
%__python2 -u ./setup.py build
|
||||
popd
|
||||
%endif
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
pushd build/pkgs/sagenb/src/%{sagenb_pkg}
|
||||
python ./setup.py build
|
||||
%__python2 ./setup.py build
|
||||
popd
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
|
@ -740,13 +765,17 @@ pushd build/pkgs/rubiks/src
|
|||
make %{?_smp_mflags} CC="gcc -fPIC" CXX="g++ -fPIC" CFLAGS="%{optflags}" CXXFLAGS="%{optflags}"
|
||||
popd
|
||||
|
||||
%if 1
|
||||
# Remove buildroot reference from cython comments
|
||||
perl -pi -e 's|%{buildroot}||g;' `find src/build/cythonized -type f`
|
||||
|
||||
# Try hard to remove buildroot from binaries
|
||||
rm -f `grep -lr "%{buildroot}" src/build/lib.linux-*/`
|
||||
rm -f `grep -lr "%{buildroot}" src/build/temp.linux-*/`
|
||||
pushd src
|
||||
python ./setup.py build
|
||||
%__python2 ./setup.py build
|
||||
popd
|
||||
%endif
|
||||
|
||||
# last build command
|
||||
rm -fr $DOT_SAGE
|
||||
|
@ -756,12 +785,17 @@ rm -fr $DOT_SAGE
|
|||
export CC=%{__cc}
|
||||
export SAGE_ROOT=%{buildroot}%{SAGE_ROOT}
|
||||
export SAGE_LOCAL=%{buildroot}%{SAGE_LOCAL}
|
||||
export SAGE_SRC=%{buildroot}%{SAGE_SRC}
|
||||
# Avoid buildroot in gcc command line (use _builddir instead)
|
||||
export SAGE_SRC="$PWD/src"
|
||||
#export SAGE_SRC=#%#{buildroot}#%#{SAGE_SRC}
|
||||
export SAGE_SHARE=%{buildroot}%{SAGE_SHARE}
|
||||
export SAGE_ETC=%{buildroot}%{SAGE_ETC}
|
||||
export SAGE_EXTCODE=%{buildroot}%{SAGE_ETC}
|
||||
export SAGE_DOC=%{buildroot}%{SAGE_DOC}
|
||||
export SAGE_PYTHONPATH=%{buildroot}%{SAGE_PYTHONPATH}
|
||||
export LD_LIBRARY_PATH=%{buildroot}%{_libdir}:$LD_LIBRARY_PATH
|
||||
%if %{with bundled_pari}
|
||||
export LD_LIBRARY_PATH=%{_builddir}/lib:$LD_LIBRARY_PATH
|
||||
%endif
|
||||
export DESTDIR=%{buildroot}
|
||||
export DOT_SAGE=/tmp/sage$$
|
||||
mkdir -p $DOT_SAGE/tmp
|
||||
|
@ -774,17 +808,15 @@ mkdir -p %{buildroot}%{_bindir}
|
|||
mkdir -p %{buildroot}%{_libdir}
|
||||
mkdir -p $SAGE_PYTHONPATH
|
||||
rm -fr $SAGE_LOCAL/{include,lib,share,notebook}
|
||||
mkdir -p $SAGE_SHARE $SAGE_DOC $SAGE_LOCAL/bin $SAGE_SRC
|
||||
ln -sf $PWD/src/sage $SAGE_SRC/sage
|
||||
mkdir -p $SAGE_SHARE $SAGE_DOC $SAGE_LOCAL/bin %{buildroot}%{SAGE_SRC}
|
||||
ln -sf $PWD/src/sage %{buildroot}%{SAGE_SRC}/sage
|
||||
ln -sf %{_libdir} $SAGE_LOCAL/lib
|
||||
ln -sf %{_includedir} $SAGE_LOCAL/include
|
||||
ln -sf %{_datadir} $SAGE_LOCAL/share
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
pushd src
|
||||
python setup.py install --root=%{buildroot}
|
||||
cp -fa c_lib/libcsage.so.0 %{buildroot}%{_libdir}
|
||||
ln -sf libcsage.so.0 %{buildroot}%{_libdir}/libcsage.so
|
||||
%__python2 -u setup.py install --root=%{buildroot}
|
||||
%if %{with docs}
|
||||
# install documentation sources
|
||||
rm -fr $SAGE_DOC/{common,en,fr}
|
||||
|
@ -792,10 +824,17 @@ 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/%{sagenb_pkg}
|
||||
rm -f %{buildroot}%{python_sitearch}/sagenb/data/sage3d/sage3d
|
||||
python setup.py install --root=%{buildroot} --install-purelib=%{python_sitearch}
|
||||
%__python2 setup.py install --root=%{buildroot} --install-purelib=%{python_sitearch}
|
||||
# jsmol
|
||||
ln -sf %{_jsdir}/jsmol $SAGE_SHARE/jsmol
|
||||
# sage3d
|
||||
|
@ -818,7 +857,10 @@ pushd src/bin
|
|||
cp -fa sage-* $SAGE_LOCAL/bin
|
||||
pushd $SAGE_LOCAL/bin
|
||||
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
|
||||
|
@ -908,12 +950,11 @@ pushd src/ext
|
|||
mkdir -p $SAGE_ETC
|
||||
for dir in \
|
||||
gap \
|
||||
graphs \
|
||||
images \
|
||||
magma \
|
||||
maxima \
|
||||
mwrank \
|
||||
singular \
|
||||
sobj; do
|
||||
notebook-ipython; do
|
||||
COUNT=`find $dir -type f | wc -l `
|
||||
if [ $COUNT -gt 0 ]; then
|
||||
cp -far $dir $SAGE_ETC
|
||||
|
@ -937,7 +978,7 @@ popd
|
|||
|
||||
#------------------------------------------------------------------------
|
||||
pushd build/pkgs/sagetex/src
|
||||
python setup.py install --root=%{buildroot} --install-purelib=%{python_sitearch}
|
||||
%__python2 setup.py install --root=%{buildroot} --install-purelib=%{python_sitearch}
|
||||
install -p -m 0644 -D %{SOURCE2} \
|
||||
%{buildroot}%{_datadir}/texmf/tex/generic/sagetex/makecmds.sty
|
||||
mv %{buildroot}%{_docdir}/{sagetex,%{sagetex_pkg}}
|
||||
|
@ -959,8 +1000,9 @@ export SAGE_TESTDIR=\$DOT_SAGE/tmp
|
|||
export SAGE_ROOT="$SAGE_ROOT"
|
||||
export SAGE_LOCAL="$SAGE_LOCAL"
|
||||
export SAGE_SHARE="$SAGE_SHARE"
|
||||
export SAGE_EXTCODE="$SAGE_ETC"
|
||||
export SAGE_ETC="$SAGE_ETC"
|
||||
export SAGE_SRC="$SAGE_SRC"
|
||||
export SAGE_SRC="%{buildroot}%{SAGE_SRC}"
|
||||
##export SAGE_DOC="$SAGE_DOC"
|
||||
module load 4ti2-%{_arch}
|
||||
module load lrcalc-%{_arch}
|
||||
|
@ -975,6 +1017,9 @@ export SAGE_FORTRAN_LIB=\`gfortran --print-file-name=libgfortran.so\`
|
|||
export SYMPOW_DIR="\$DOT_SAGE/sympow"
|
||||
export LC_MESSAGES=C
|
||||
export LC_NUMERIC=C
|
||||
export LD_LIBRARY_PATH=\$SAGE_ROOT/lib:\$LD_LIBRARY_PATH
|
||||
# Required for sage -gdb
|
||||
export SAGE_DEBUG=no
|
||||
$SAGE_LOCAL/bin/sage "\$@"
|
||||
EOF
|
||||
#------------------------------------------------------------------------
|
||||
|
@ -995,9 +1040,6 @@ chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage3d
|
|||
# o install csage headers
|
||||
# o install .pxi and .pxd files
|
||||
pushd src
|
||||
# make csage headers available
|
||||
mkdir -p %{buildroot}%{_includedir}/csage
|
||||
cp -fa c_lib/include/* %{buildroot}%{_includedir}/csage
|
||||
for f in `find sage \( -name \*.pxi -o -name \*.pxd -o -name \*.pyx \)`; do
|
||||
install -p -D -m 0644 $f %{buildroot}%{python_sitearch}/$f
|
||||
done
|
||||
|
@ -1016,7 +1058,7 @@ pushd src/doc
|
|||
export PATH=%{buildroot}%{_bindir}:$SAGE_LOCAL/bin:$PATH
|
||||
export SINGULARPATH=%{_libdir}/Singular/LIB
|
||||
export SINGULAR_BIN_DIR=%{_libdir}/Singular
|
||||
export LD_LIBRARY_PATH=%{buildroot}%{_libdir}:%{_libdir}/atlas:$LD_LIBRARY_PATH
|
||||
export LD_LIBRARY_PATH=%{_libdir}/atlas:$LD_LIBRARY_PATH
|
||||
export PYTHONPATH=%{buildroot}%{python_sitearch}:$SAGE_PYTHONPATH:$SAGE_DOC
|
||||
|
||||
%if %{with sphinx_hack}
|
||||
|
@ -1026,13 +1068,23 @@ pushd src/doc
|
|||
%endif
|
||||
|
||||
# there we go
|
||||
ln -sf %{buildroot}%{SAGE_DOC} $SAGE_SRC/doc
|
||||
LANGUAGES="ca de en fr hu it pt ru tr" python common/builder.py -k all html
|
||||
ln -sf %{buildroot}%{SAGE_DOC} %{buildroot}%{SAGE_SRC}/doc
|
||||
LANGUAGES="ca de en fr hu it pt ru tr" \
|
||||
%__python2 common/builder.py --no-pdf-links -k all html
|
||||
export SAGE_DOC=%{buildroot}%{SAGE_DOC}
|
||||
cp -far output $SAGE_DOC
|
||||
rm -f %{buildroot}%{SAGE_SRC}/doc
|
||||
ln -sf %{SAGE_DOC} %{buildroot}%{SAGE_SRC}/doc
|
||||
|
||||
# should not be required and encodes buildroot
|
||||
rm -fr $SAGE_DOC/output/doctrees
|
||||
|
||||
# FIXME missing
|
||||
for css in $(find $SAGE_DOC/output/html -name classic.css); do
|
||||
pushd $(dirname $css)
|
||||
ln -s classic.css default.css
|
||||
popd
|
||||
done
|
||||
popd
|
||||
|
||||
%if %{with check}
|
||||
|
@ -1120,9 +1172,68 @@ rm %{buildroot}%{python_sitearch}/sagenb/translations/*/LC_MESSAGES/*.po
|
|||
rm -r %{buildroot}%{python_sitearch}/sagenb/data/sage3d
|
||||
%endif
|
||||
|
||||
# remove build directory in buildroot
|
||||
[ -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|^(extra_link_args = \[.*)]|$1, "-L%{SAGE_ROOT}/lib"\]|;' %{buildroot}%{python_sitearch}/sage/misc/cython.py
|
||||
%endif
|
||||
|
||||
# remove sage_setup
|
||||
rm -r %{buildroot}%{python_sitearch}/sage_setup
|
||||
|
||||
# pretend sagemath spkgs are installed to reduce number of errors
|
||||
# in doctests
|
||||
mkdir -p %{buildroot}%{SAGE_SPKG_INST}
|
||||
pushd upstream
|
||||
for file in *.tar.*; do
|
||||
touch %{buildroot}%{SAGE_SPKG_INST}/$(echo $file | sed -e 's|\.tar.*||')
|
||||
done
|
||||
popd
|
||||
#------------------------------------------------------------------------
|
||||
cat > %{buildroot}%{SAGE_LOCAL}/bin/sage-list-packages << EOF
|
||||
#!/bin/sh
|
||||
NOVERSION=false
|
||||
INSTALLED=no
|
||||
while [ \$# -gt 0 ]; do
|
||||
if [ x\$1 = x--no-version ]; then
|
||||
NOVERSION=true
|
||||
elif [ x\$1 = xinstalled ]; then
|
||||
INSTALLED=yes
|
||||
fi
|
||||
shift
|
||||
done
|
||||
if [ \$INSTALLED = no ]; then
|
||||
exit 0
|
||||
fi
|
||||
LIST=\$(cd %{SAGE_SPKG_INST}; echo *)
|
||||
if [ \$NOVERSION = false ]; then
|
||||
for pkg in \$LIST; do
|
||||
echo \$pkg | sed -e 's/-/ /'
|
||||
done
|
||||
else
|
||||
for pkg in \$LIST; do
|
||||
echo \$pkg | sed -e 's/-.*//'
|
||||
done
|
||||
fi
|
||||
EOF
|
||||
chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage-list-packages
|
||||
#------------------------------------------------------------------------
|
||||
|
||||
# last install command
|
||||
rm -fr $DOT_SAGE
|
||||
|
||||
|
@ -1155,6 +1266,10 @@ 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/python
|
||||
%{SAGE_LOCAL}/bin/sage*
|
||||
%{SAGE_LOCAL}/include
|
||||
%{SAGE_LOCAL}/lib
|
||||
|
@ -1163,7 +1278,9 @@ exit 0
|
|||
%{SAGE_ROOT}/devel
|
||||
%{SAGE_ROOT}/share
|
||||
%dir %{SAGE_SRC}
|
||||
%if %{with docs}
|
||||
%{SAGE_SRC}/doc
|
||||
%endif
|
||||
%{SAGE_SRC}/sage
|
||||
%dir %{SAGE_PYTHONPATH}
|
||||
# MIT
|
||||
|
@ -1172,11 +1289,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+
|
||||
%{_libdir}/libcsage.so.*
|
||||
%{python_sitearch}/sage
|
||||
%{python_sitearch}/sage-*.egg-info
|
||||
|
||||
|
@ -1202,15 +1323,17 @@ exit 0
|
|||
%files data-etc
|
||||
# GPLv2+
|
||||
%{SAGE_ETC}/gap
|
||||
#%#{SAGE_ETC}/graphs
|
||||
%{SAGE_ETC}/images
|
||||
%{SAGE_ETC}/magma
|
||||
%{SAGE_ETC}/maxima
|
||||
%{SAGE_ETC}/mwrank
|
||||
#%#{SAGE_ETC}/notebook-ipython
|
||||
%{SAGE_ETC}/pari
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%files data-graphs
|
||||
# GPLv2+
|
||||
%{SAGE_ETC}/graphs
|
||||
%{SAGE_SHARE}/graphs
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
|
@ -1218,12 +1341,6 @@ exit 0
|
|||
# GPL+
|
||||
%{SAGE_SHARE}/reflexive_polytopes
|
||||
|
||||
#------------------------------------------------------------------------
|
||||
%files devel
|
||||
# GPLv2+
|
||||
%{_includedir}/csage
|
||||
%{_libdir}/libcsage.so
|
||||
|
||||
%if %{with docs}
|
||||
#------------------------------------------------------------------------
|
||||
%files doc
|
||||
|
@ -1291,6 +1408,7 @@ exit 0
|
|||
|
||||
#------------------------------------------------------------------------
|
||||
%files notebook
|
||||
%{SAGE_ETC}/notebook-ipython
|
||||
# GPLv2+
|
||||
%{SAGE_SRC}/sagenb
|
||||
%dir %{python_sitearch}/sagenb
|
||||
|
@ -1376,6 +1494,11 @@ exit 0
|
|||
|
||||
########################################################################
|
||||
%changelog
|
||||
* Tue Dec 22 2015 pcpa <paulo.cesar.pereira.de.andrade@gmail.com> - 6.8-1
|
||||
- Update to sagemath 6.8
|
||||
- Remove scons, lrcalc, cryptominisat, parallel and ipython3 patches
|
||||
- Add lcalc, fes-build and arb patches
|
||||
|
||||
* Fri Dec 4 2015 Jerry James <loganjerry@gmail.com> - 6.5-14
|
||||
- Rebuild for ntl 9.6.2
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue