Update to sagemath 8.4.

Also:
- Build for python 3 instead of python 2 due to upcoming python 2 removal.
- Add -python3 and -escape patches to fix problems with python 3.
- Drop -nofstring patch, only needed for python 2.
- Drop upstreamed -eclib patch.
- Switch from atlas to openblas and rename -atlas patch to -openblas.
- Add -buildroot patch and only build cython interfaces once.
This commit is contained in:
Jerry James 2018-11-01 19:25:26 -06:00
parent 1a0bd1afc6
commit eaa777c690
19 changed files with 1557 additions and 473 deletions

View file

@ -1,17 +1,17 @@
diff -up src/sage/sandpiles/sandpile.py.orig src/sage/sandpiles/sandpile.py
--- src/sage/sandpiles/sandpile.py.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage/sandpiles/sandpile.py 2018-08-29 08:47:29.728055776 -0600
@@ -342,9 +342,6 @@ from sage.arith.all import falling_facto
--- src/sage/sandpiles/sandpile.py.orig 2018-10-17 17:14:17.000000000 -0600
+++ src/sage/sandpiles/sandpile.py 2018-10-25 13:18:34.198894883 -0600
@@ -344,9 +344,6 @@ from sage.arith.all import falling_facto
from sage.rings.all import Integer, PolynomialRing, QQ, ZZ
from sage.symbolic.all import I, pi
from sage.symbolic.all import I, pi, SR
-# TODO: remove the following line once 4ti2 functions are removed
-path_to_zsolve = os.path.join(SAGE_LOCAL,'bin','zsolve')
-path_to_zsolve = os.path.join(SAGE_LOCAL, 'bin', 'zsolve')
-
class Sandpile(DiGraph):
"""
Class for Dhar's abelian sandpile model.
@@ -5197,7 +5194,7 @@ class SandpileDivisor(dict):
def _sandpile_help(cls, usage, verbose=True):
@@ -5150,7 +5147,7 @@ class SandpileDivisor(dict):
sign_file.close()
# compute
try:

12
sagemath-buildroot.patch Normal file
View file

@ -0,0 +1,12 @@
--- src/setup.py.orig 2018-10-16 09:07:30.086993782 -0600
+++ src/setup.py 2018-10-16 09:10:20.586710425 -0600
@@ -387,6 +387,9 @@ class sage_build_cython(Command):
with open(self._version_file, 'w') as f:
f.write(self._version_stamp)
+ # Remove buildroot paths from the generated files
+ subprocess.run(["find", "build/cythonized/sage", "-type", "f", "-exec", "sed", "-i", "s|@@BUILDROOT@@||g", "{}", "+"], check=True)
+
# Finally, copy relevant cythonized files from build/cythonized
# tree into the build-lib tree
for (dst_dir, src_files) in self.get_cythonized_package_files():

View file

@ -1,12 +1,12 @@
diff -up src/sage/databases/cremona.py.orig src/sage/databases/cremona.py
--- src/sage/databases/cremona.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/databases/cremona.py 2018-08-29 08:48:43.090148635 -0600
--- src/sage/databases/cremona.py.orig 2018-10-17 17:13:36.000000000 -0600
+++ src/sage/databases/cremona.py 2018-10-25 13:24:02.644939224 -0600
@@ -53,7 +53,6 @@ from sage.misc.prandom import randint
import sage.schemes.elliptic_curves.constructor as elliptic
from .sql_db import SQLDatabase, verify_column
-from sage.misc.package import is_package_installed
from sage.env import SAGE_SHARE
from sage.env import CREMONA_MINI_DATA_DIR, CREMONA_LARGE_DATA_DIR
from sage.misc.all import walltime
@@ -825,14 +824,6 @@ class MiniCremonaDatabase(SQLDatabase):

View file

@ -1,22 +0,0 @@
--- src/sage/libs/eclib/wrap.cpp.orig 2018-05-05 16:21:24.000000000 -0600
+++ src/sage/libs/eclib/wrap.cpp 2018-08-09 21:57:02.055392569 -0600
@@ -133,8 +133,8 @@ char* Curvedata_isogeny_class(struct Cur
int mw_process(struct Curvedata* curve, struct mw* m,
- const struct bigint* x, const struct bigint* y,
- const struct bigint* z, int sat)
+ const bigint* x, const bigint* y,
+ const bigint* z, int sat)
{
Point P(*curve, *x, *y, *z);
if (!P.isvalid())
@@ -188,7 +188,7 @@ int mw_rank(struct mw* m)
}
/* Returns index and unsat long array, which user must deallocate */
-int mw_saturate(struct mw* m, struct bigint* index, char** unsat,
+int mw_saturate(struct mw* m, bigint* index, char** unsat,
long sat_bd, int odd_primes_only)
{
vector<long> v;

108
sagemath-escape.patch Normal file
View file

@ -0,0 +1,108 @@
--- build/pkgs/sagenb/src/sagenb/misc/sphinxify.py.orig 2018-10-25 14:14:33.031253545 -0600
+++ build/pkgs/sagenb/src/sagenb/misc/sphinxify.py 2018-10-25 15:33:56.358876835 -0600
@@ -133,7 +133,7 @@ def sphinxify(docstring, format='html'):
# "/media/...path.../blah.png"
# to
# "/doc/static/reference/media/...path.../blah.png"
- output = re.sub("""src=['"](/?\.\.)*/?media/([^"']*)['"]""",
+ output = re.sub("""src=['"](/?\\.\\.)*/?media/([^"']*)['"]""",
'src="/doc/static/reference/media/\\2"',
output)
# Remove spurious \(, \), \[, \].
--- build/pkgs/sagenb/src/sagenb/misc/support.py.orig 2018-10-25 13:30:02.499892169 -0600
+++ build/pkgs/sagenb/src/sagenb/misc/support.py 2018-10-25 14:14:33.032253542 -0600
@@ -550,7 +550,7 @@ try:
return args[0].__getattribute__(str(self))(*args[1:], **kwds)
def automatic_name_eval(s, globals, max_names=10000):
- """
+ r"""
Exec the string ``s`` in the scope of the ``globals``
dictionary, and if any :exc:`NameError`\ s are raised, try to
fix them by defining the variable that caused the error to be
--- build/pkgs/sagenb/src/sagenb/notebook/cell.py.orig 2018-10-25 13:30:55.707737342 -0600
+++ build/pkgs/sagenb/src/sagenb/notebook/cell.py 2018-10-25 14:14:33.032253542 -0600
@@ -441,7 +441,7 @@ class Cell_generic(object):
return isinstance(self, Cell)
def is_auto_cell(self):
- """
+ r"""
Returns whether this is an automatically evaluated generic
cell. This is always false for :class:`Cell_generic`\ s and
:class:`TextCell`\ s.
@@ -647,7 +647,7 @@ class TextCell(Cell_generic):
return self._text
def set_cell_output_type(self, typ='wrap'):
- """
+ r"""
Sets this text cell's output type. This does nothing for
:class:`TextCell`\ s.
@@ -1320,8 +1320,8 @@ class Cell(Cell_generic):
if len(s) == 0:
return False
s = s[0]
- return bool(re.search('(?<!\w)interact\s*\(.*\).*', s) or
- re.search('\s*@\s*interact', s))
+ return bool(re.search(r'(?<!\w)interact\s*\(.*\).*', s) or
+ re.search(r'\s*@\s*interact', s))
def is_interacting(self):
r"""
@@ -1344,7 +1344,7 @@ class Cell(Cell_generic):
return hasattr(self, 'interact')
def stop_interacting(self):
- """
+ r"""
Stops :func:`sagenb.notebook.interact.interact`\ ion for this
compute cell.
--- build/pkgs/sagenb/src/sagenb/notebook/worksheet.py.orig 2018-05-22 10:01:48.000000000 -0600
+++ build/pkgs/sagenb/src/sagenb/notebook/worksheet.py 2018-10-17 14:41:08.634154908 -0600
@@ -61,8 +61,8 @@ from flask_babel import gettext, lazy_ge
_ = gettext
# Set some constants that will be used for regular expressions below.
-whitespace = re.compile('\s') # Match any whitespace character
-non_whitespace = re.compile('\S')
+whitespace = re.compile(r'\s') # Match any whitespace character
+non_whitespace = re.compile(r'\S')
# The file to which the Sage code that will be evaluated is written.
CODE_PY = "___code___.py"
--- src/sage/combinat/cluster_algebra_quiver/quiver_mutation_type.py.orig 2018-10-17 17:13:35.000000000 -0600
+++ src/sage/combinat/cluster_algebra_quiver/quiver_mutation_type.py 2018-10-25 14:14:33.033253539 -0600
@@ -2023,7 +2023,7 @@ class QuiverMutationType_Reducible(Quive
@cached_method
def class_size(self):
- """
+ r"""
If it is known, the size of the mutation class of all quivers
which are mutation equivalent to the standard quiver of
``self`` (up to isomorphism) is returned.
--- src/sage/combinat/crystals/alcove_path.py.orig 2018-10-17 17:13:35.000000000 -0600
+++ src/sage/combinat/crystals/alcove_path.py 2018-10-25 15:37:04.294360718 -0600
@@ -389,7 +389,7 @@ class CrystalOfAlcovePaths(UniqueReprese
One can compute all vertices of the crystal by finding all the
admissible subsets of the `\lambda`-chain (see method
- is_admissible, for definition). We use the breath first
+ is_admissible, for definition). We use the breadth first
search algorithm.
.. WARNING::
--- src/sage/homology/homology_group.py.orig 2018-10-17 17:13:47.000000000 -0600
+++ src/sage/homology/homology_group.py 2018-10-25 15:54:54.683421705 -0600
@@ -109,7 +109,7 @@ class HomologyGroup_class(AdditiveAbelia
sage: from sage.homology.homology_group import HomologyGroup
sage: H = HomologyGroup(7, ZZ, [4,4,4,4,4,7,7])
sage: H._latex_()
- 'C_{4}^{5} \\times C_{7} \\times C_{7}'
+ 'C_{4}^{5} \times C_{7} \times C_{7}'
sage: latex(HomologyGroup(6, ZZ))
\ZZ^{6}
"""

View file

@ -1,6 +1,6 @@
diff -up src/module_list.py.orig src/module_list.py
--- src/module_list.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/module_list.py 2018-08-29 08:34:50.846439644 -0600
--- src/module_list.py.orig 2018-10-17 17:13:35.000000000 -0600
+++ src/module_list.py 2018-10-25 11:33:55.361930982 -0600
@@ -358,16 +358,16 @@ ext_modules = [
Extension('sage.graphs.matchpoly',
sources = ['sage/graphs/matchpoly.pyx']),
@ -72,44 +72,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.libs.flint.flint',
sources = ["sage/libs/flint/flint.pyx"],
@@ -495,22 +494,22 @@ ext_modules = [
Extension('sage.libs.gmp.pylong',
sources = ['sage/libs/gmp/pylong.pyx']),
- OptionalExtension('sage.libs.braiding',
- sources = ["sage/libs/braiding.pyx"],
- libraries = ["braiding"],
- package="libbraiding",
- language = 'c++'),
+# OptionalExtension('sage.libs.braiding',
+# sources = ["sage/libs/braiding.pyx"],
+# libraries = ["braiding"],
+# package="libbraiding",
+# language = 'c++'),
- OptionalExtension('sage.libs.homfly',
- sources = ["sage/libs/homfly.pyx"],
- libraries = ["homfly", "gc"],
- package="libhomfly"),
+# OptionalExtension('sage.libs.homfly',
+# sources = ["sage/libs/homfly.pyx"],
+# libraries = ["homfly", "gc"],
+# package="libhomfly"),
- OptionalExtension('sage.libs.sirocco',
- sources = ["sage/libs/sirocco.pyx"],
- libraries = ["sirocco"],
- package="sirocco",
- language = 'c++'),
+# OptionalExtension('sage.libs.sirocco',
+# sources = ["sage/libs/sirocco.pyx"],
+# libraries = ["sirocco"],
+# package="sirocco",
+# language = 'c++'),
Extension('*', ['sage/libs/linbox/*.pyx']),
@@ -843,10 +842,10 @@ ext_modules = [
@@ -841,10 +840,10 @@ ext_modules = [
Extension('sage.matrix.matrix_window',
sources = ['sage/matrix/matrix_window.pyx']),
@ -124,7 +87,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.matrix.misc',
sources = ['sage/matrix/misc.pyx']),
@@ -1023,26 +1022,25 @@ ext_modules = [
@@ -1021,26 +1020,25 @@ ext_modules = [
Extension("sage.numerical.backends.interactivelp_backend",
["sage/numerical/backends/interactivelp_backend.pyx"]),

View file

@ -1,6 +1,6 @@
diff -up src/module_list.py.orig src/module_list.py
--- src/module_list.py.orig 2018-08-29 10:41:05.127643255 -0600
+++ src/module_list.py 2018-08-29 10:44:16.376279329 -0600
--- src/module_list.py.orig 2018-10-25 11:40:44.400943439 -0600
+++ src/module_list.py 2018-10-25 16:16:46.618825285 -0600
@@ -45,6 +45,9 @@ zlib_libs = zlib_pc['libraries']
zlib_library_dirs = zlib_pc['library_dirs']
zlib_include_dirs = zlib_pc['include_dirs']
@ -36,7 +36,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('*', sources = ['sage/algebras/finite_dimensional_algebras/*.pyx']),
@@ -526,7 +538,8 @@ ext_modules = [
@@ -524,7 +536,8 @@ ext_modules = [
[])),
Extension('sage.libs.lrcalc.lrcalc',
@ -46,7 +46,7 @@ diff -up src/module_list.py.orig src/module_list.py
OptionalExtension("sage.libs.meataxe",
sources = ['sage/libs/meataxe.pyx'],
@@ -548,23 +561,28 @@ ext_modules = [
@@ -546,23 +559,28 @@ ext_modules = [
sources = ['sage/libs/readline.pyx'],
libraries = ['readline']),
@ -80,7 +80,7 @@ diff -up src/module_list.py.orig src/module_list.py
###################################
##
@@ -572,7 +590,8 @@ ext_modules = [
@@ -570,7 +588,8 @@ ext_modules = [
##
###################################
@ -90,7 +90,7 @@ diff -up src/module_list.py.orig src/module_list.py
###################################
##
@@ -744,7 +763,8 @@ ext_modules = [
@@ -742,7 +761,8 @@ ext_modules = [
Extension("sage.matrix.matrix_complex_ball_dense",
["sage/matrix/matrix_complex_ball_dense.pyx"],
@ -100,7 +100,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.matrix.matrix_complex_double_dense',
sources = ['sage/matrix/matrix_complex_double_dense.pyx']),
@@ -752,6 +772,7 @@ ext_modules = [
@@ -750,6 +770,7 @@ ext_modules = [
Extension('sage.matrix.matrix_cyclo_dense',
sources = ['sage/matrix/matrix_cyclo_dense.pyx'],
language = "c++",
@ -108,7 +108,7 @@ diff -up src/module_list.py.orig src/module_list.py
libraries=['ntl']),
Extension('sage.matrix.matrix_gap',
@@ -814,6 +835,7 @@ ext_modules = [
@@ -812,6 +833,7 @@ ext_modules = [
sources = ['sage/matrix/matrix_modn_sparse.pyx']),
Extension('sage.matrix.matrix_mpolynomial_dense',
@ -116,7 +116,7 @@ diff -up src/module_list.py.orig src/module_list.py
sources = ['sage/matrix/matrix_mpolynomial_dense.pyx']),
Extension('sage.matrix.matrix_polynomial_dense',
@@ -1111,7 +1133,8 @@ ext_modules = [
@@ -1109,7 +1131,8 @@ ext_modules = [
language = 'c++'),
Extension("sage.rings.complex_arb",
@ -126,7 +126,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.rings.complex_double',
sources = ['sage/rings/complex_double.pyx'],
@@ -1181,7 +1204,8 @@ ext_modules = [
@@ -1179,7 +1202,8 @@ ext_modules = [
sources = ['sage/rings/real_interval_absolute.pyx']),
Extension("sage.rings.real_arb",
@ -136,7 +136,7 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.rings.real_lazy',
sources = ['sage/rings/real_lazy.pyx']),
@@ -1264,6 +1288,7 @@ ext_modules = [
@@ -1262,6 +1286,7 @@ ext_modules = [
Extension('sage.rings.number_field.number_field_element_quadratic',
sources = ['sage/rings/number_field/number_field_element_quadratic.pyx'],
@ -144,7 +144,7 @@ diff -up src/module_list.py.orig src/module_list.py
libraries=['ntl'],
language = 'c++'),
@@ -1386,12 +1411,15 @@ ext_modules = [
@@ -1401,12 +1426,15 @@ ext_modules = [
sources = ['sage/rings/polynomial/multi_polynomial.pyx']),
Extension('sage.rings.polynomial.multi_polynomial_ideal_libsingular',
@ -160,7 +160,7 @@ diff -up src/module_list.py.orig src/module_list.py
sources = ['sage/rings/polynomial/multi_polynomial_libsingular.pyx']),
Extension('sage.rings.polynomial.multi_polynomial_ring_base',
@@ -1404,7 +1432,8 @@ ext_modules = [
@@ -1419,7 +1447,8 @@ ext_modules = [
sources = ['sage/rings/polynomial/polydict.pyx']),
Extension('sage.rings.polynomial.polynomial_complex_arb',
@ -170,9 +170,9 @@ diff -up src/module_list.py.orig src/module_list.py
Extension('sage.rings.polynomial.polynomial_compiled',
sources = ['sage/rings/polynomial/polynomial_compiled.pyx']),
diff -up src/setup.py.orig src/setup.py
--- src/setup.py.orig 2018-08-29 08:35:19.955079610 -0600
+++ src/setup.py 2018-08-29 10:44:16.376279329 -0600
diff -du src/setup.py.orig src/setup.py
--- src/setup.py.orig 2018-10-25 14:05:20.779815082 -0600
+++ src/setup.py 2018-10-25 16:16:46.619825283 -0600
@@ -85,6 +85,7 @@ except KeyError:
# search for dependencies and add to gcc -I<path>

View file

@ -1,12 +1,12 @@
diff -up src/sage/interfaces/jmoldata.py.orig src/sage/interfaces/jmoldata.py
--- src/sage/interfaces/jmoldata.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/interfaces/jmoldata.py 2018-08-29 08:47:39.203938604 -0600
--- src/sage/interfaces/jmoldata.py.orig 2018-10-17 17:13:47.000000000 -0600
+++ src/sage/interfaces/jmoldata.py 2018-10-25 13:22:07.965272901 -0600
@@ -148,8 +148,6 @@ class JmolData(SageObject):
sage: print(os.path.exists(testfile)) # optional -- java
True
"""
- # Set up paths, file names and scripts
- jmolpath = os.path.join(SAGE_LOCAL, "share", "jmol", "JmolData.jar")
- jmolpath = os.path.join(JMOL_DIR, "JmolData.jar")
target_native = targetfile
if sys.platform == 'cygwin':

View file

@ -1,30 +1,18 @@
diff -up src/sage/env.py.orig src/sage/env.py
--- src/sage/env.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/env.py 2018-08-29 11:25:26.833962117 -0600
--- src/sage/env.py.orig 2018-10-17 17:13:36.000000000 -0600
+++ src/sage/env.py 2018-10-25 14:10:21.564960823 -0600
@@ -164,7 +164,7 @@ _add_variable_or_fallback('CONWAY_POLYNO
_add_variable_or_fallback('GRAPHS_DATA_DIR', opj('$SAGE_SHARE','graphs'))
_add_variable_or_fallback('ELLCURVE_DATA_DIR',opj('$SAGE_SHARE','ellcurves'))
_add_variable_or_fallback('POLYTOPE_DATA_DIR',opj('$SAGE_SHARE','reflexive_polytopes'))
-_add_variable_or_fallback('GAP_ROOT_DIR', opj('$SAGE_LOCAL','gap','latest'))
+_add_variable_or_fallback('GAP_ROOT_DIR', opj('usr','lib','gap'))
+_add_variable_or_fallback('GAP_ROOT_DIR', opj('/usr','lib','gap'))
_add_variable_or_fallback('THEBE_DIR', opj('$SAGE_SHARE','thebe'))
# locate singular shared object
diff -up src/sage/interfaces/gap.py.orig src/sage/interfaces/gap.py
--- src/sage/interfaces/gap.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/interfaces/gap.py 2018-08-29 11:21:43.180584324 -0600
@@ -197,7 +197,7 @@ import string
WORKSPACE = gap_workspace_file()
-GAP_BINARY = os.path.join(SAGE_LOCAL, 'bin', 'gap')
+GAP_BINARY = os.path.join('usr', 'bin', 'gap')
first_try = True
_add_variable_or_fallback('COMBINATORIAL_DESIGN_DATA_DIR', opj('$SAGE_SHARE', 'combinatorial_designs'))
_add_variable_or_fallback('CREMONA_MINI_DATA_DIR', opj('$SAGE_SHARE', 'cremona'))
diff -up src/sage/libs/gap/test/main.c.orig src/sage/libs/gap/test/main.c
--- src/sage/libs/gap/test/main.c.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/libs/gap/test/main.c 2018-08-29 10:38:22.512653256 -0600
--- src/sage/libs/gap/test/main.c.orig 2018-10-17 17:13:52.000000000 -0600
+++ src/sage/libs/gap/test/main.c 2018-10-25 14:05:51.458727612 -0600
@@ -22,7 +22,7 @@ void eval(char* cmd) {
libgap_start_interaction(cmd);
@ -35,8 +23,8 @@ diff -up src/sage/libs/gap/test/main.c.orig src/sage/libs/gap/test/main.c
char* out = libgap_get_output();
libgap_exit();
diff -up src/sage/libs/gap/util.pyx.orig src/sage/libs/gap/util.pyx
--- src/sage/libs/gap/util.pyx.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/libs/gap/util.pyx 2018-08-29 11:32:06.654205922 -0600
--- src/sage/libs/gap/util.pyx.orig 2018-10-25 13:50:51.168295628 -0600
+++ src/sage/libs/gap/util.pyx 2018-10-25 14:05:51.458727612 -0600
@@ -25,6 +25,8 @@ from sage.cpython.string cimport str_to_
from sage.interfaces.gap_workspace import prepare_workspace_dir
from sage.env import SAGE_LOCAL, GAP_ROOT_DIR

View file

@ -1,6 +1,6 @@
diff -up src/bin/sage-maxima.lisp.orig src/bin/sage-maxima.lisp
--- src/bin/sage-maxima.lisp.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/bin/sage-maxima.lisp 2018-08-29 08:45:21.302643791 -0600
--- src/bin/sage-maxima.lisp.orig 2018-10-17 17:13:34.000000000 -0600
+++ src/bin/sage-maxima.lisp 2018-10-25 13:14:53.465538639 -0600
@@ -4,3 +4,8 @@
(setf *prompt-prefix* "<sage-display>")
@ -11,12 +11,12 @@ diff -up src/bin/sage-maxima.lisp.orig src/bin/sage-maxima.lisp
+ *standard-input* (open "/dev/stdin" :direction :input)
+ *standard-output* (open "/dev/stdout" :direction :output))
diff -up src/sage/interfaces/maxima.py.orig src/sage/interfaces/maxima.py
--- src/sage/interfaces/maxima.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/interfaces/maxima.py 2018-08-29 08:47:09.779302448 -0600
--- src/sage/interfaces/maxima.py.orig 2018-10-17 17:13:51.000000000 -0600
+++ src/sage/interfaces/maxima.py 2018-10-25 13:16:00.326343444 -0600
@@ -546,7 +546,7 @@ class Maxima(MaximaAbstract, Expect):
Expect.__init__(self,
name = 'maxima',
prompt = '\(\%i[0-9]+\) ',
prompt = r'\(\%i[0-9]+\) ',
- command = 'maxima -p "{0}"'.format(STARTUP),
+ command = 'maxima --disable-readline -p "{0}"'.format(STARTUP),
env = {'TMPDIR': str(ECL_TMP)},

View file

@ -12,7 +12,7 @@ diff -up src/sage/libs/mpfr/__init__.pxd.orig src/sage/libs/mpfr/__init__.pxd
diff -up src/sage/rings/complex_mpc.pyx.orig src/sage/rings/complex_mpc.pyx
--- src/sage/rings/complex_mpc.pyx.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage/rings/complex_mpc.pyx 2018-08-29 10:41:34.027286042 -0600
@@ -2221,7 +2221,7 @@ cdef class MPComplexNumber(sage.structur
@@ -2225,7 +2225,7 @@ cdef class MPComplexNumber(sage.structur
cdef RealNumber a,r
a = self.argument()/n
r = self.abs()

View file

@ -1,7 +1,7 @@
diff -up src/sage/graphs/graph_generators.py.orig src/sage/graphs/graph_generators.py
--- src/sage/graphs/graph_generators.py.orig 2018-08-29 08:52:26.099392035 -0600
+++ src/sage/graphs/graph_generators.py 2018-08-29 08:56:44.782205619 -0600
@@ -906,7 +906,7 @@ class GraphGenerators():
--- src/sage/graphs/graph_generators.py.orig 2018-10-17 17:13:47.000000000 -0600
+++ src/sage/graphs/graph_generators.py 2018-10-25 14:04:50.496901422 -0600
@@ -911,7 +911,7 @@ class GraphGenerators():
else:
enc_kwargs = {'encoding': 'latin-1'}

View file

@ -1,60 +0,0 @@
diff -up src/sage/arith/multi_modular.pyx.orig src/sage/arith/multi_modular.pyx
--- src/sage/arith/multi_modular.pyx.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/arith/multi_modular.pyx 2018-08-29 10:44:04.624424587 -0600
@@ -173,9 +173,9 @@ cdef class MultiModularBasis_base(object
ArithmeticError: The inverse of 6 modulo 10 is not defined.
"""
if l_bound < 2:
- raise ValueError(f"minimum value for lower bound is 2, given: {l_bound}")
+ raise ValueError("minimum value for lower bound is 2, given: {l_bound}".format(l_bound=l_bound))
if u_bound > MAX_MODULUS:
- raise ValueError(f"upper bound cannot be greater than {MAX_MODULUS}, given: {u_bound}")
+ raise ValueError("upper bound cannot be greater than {MAX_MODULUS}, given: {u_bound}".format(MAX_MODULUS=MAX_MODULUS, u_bound=u_bound))
self._l_bound = l_bound
self._u_bound = u_bound
@@ -234,7 +234,7 @@ cdef class MultiModularBasis_base(object
if check:
for p in plist:
if p > MAX_MODULUS:
- raise OverflowError(f"given modulus {p} is larger than {MAX_MODULUS}")
+ raise OverflowError("given modulus {p} is larger than {MAX_MODULUS}".format(p=p, MAX_MODULUS=MAX_MODULUS))
self._realloc_to_new_count(self.n + len_plist)
cdef Py_ssize_t i
diff -up src/sage/rings/finite_rings/integer_mod.pyx.orig src/sage/rings/finite_rings/integer_mod.pyx
--- src/sage/rings/finite_rings/integer_mod.pyx.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage/rings/finite_rings/integer_mod.pyx 2018-08-29 10:44:04.624424587 -0600
@@ -468,7 +468,7 @@ cdef class IntegerMod_abstract(FiniteRin
from .integer_mod_ring import IntegerModRing
R = IntegerModRing(modulus)
if (<Element>self)._parent._IntegerModRing_generic__order % R.order():
- raise ArithmeticError(f"reduction modulo {modulus!r} not defined")
+ raise ArithmeticError("reduction modulo {modulus} not defined".format(modulus=repr(modulus)))
return R(self)
def is_nilpotent(self):
diff -up src/sage/structure/parent.pyx.orig src/sage/structure/parent.pyx
--- src/sage/structure/parent.pyx.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage/structure/parent.pyx 2018-08-29 10:44:04.625424574 -0600
@@ -726,7 +726,7 @@ cdef class Parent(sage.structure.categor
cdef int init_coerce(self, bint warn=True) except -1:
if self._coerce_from_hash is None:
if warn:
- raise AssertionError(f"unexpected call of init_coerce() for {type(self)}")
+ raise AssertionError("unexpected call of init_coerce() for {typ}".format(typ=type(self)))
self._initial_coerce_list = []
self._initial_action_list = []
self._initial_convert_list = []
diff -up src/sage/symbolic/ring.pyx.orig src/sage/symbolic/ring.pyx
--- src/sage/symbolic/ring.pyx.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage/symbolic/ring.pyx 2018-08-29 10:44:04.625424574 -0600
@@ -378,7 +378,7 @@ cdef class SymbolicRing(CommutativeRing)
from sage.misc.all import prod
return prod([SR(p)**e for p,e in x], SR(x.unit()))
else:
- raise TypeError(f"unable to convert {x!r} to a symbolic expression")
+ raise TypeError("unable to convert {x} to a symbolic expression".format(x=repr(x)))
return new_Expression_from_GEx(self, exp)

View file

@ -6,7 +6,7 @@ diff -up src/module_list.py.orig src/module_list.py
# CBLAS can be one of multiple implementations
-cblas_pc = pkgconfig.parse('cblas')
+cblas_pc = pkgconfig.parse('atlas')
+cblas_pc = pkgconfig.parse('openblas')
cblas_libs = cblas_pc['libraries']
cblas_library_dirs = cblas_pc['library_dirs']
cblas_include_dirs = cblas_pc['include_dirs']
@ -33,7 +33,7 @@ diff -up src/sage/misc/cython.py.orig src/sage/misc/cython.py
# CBLAS can be one of multiple implementations
-cblas_pc = pkgconfig.parse('cblas')
+cblas_pc = pkgconfig.parse('atlas')
+cblas_pc = pkgconfig.parse('openblas')
cblas_libs = list(cblas_pc['libraries'])
cblas_library_dirs = list(cblas_pc['library_dirs'])
cblas_include_dirs = list(cblas_pc['include_dirs'])

1075
sagemath-python3.patch Normal file

File diff suppressed because it is too large Load diff

View file

@ -1,7 +1,7 @@
diff -up src/sage/doctest/control.py.orig src/sage/doctest/control.py
--- src/sage/doctest/control.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/doctest/control.py 2018-08-29 08:36:07.805487927 -0600
@@ -102,7 +102,6 @@ class DocTestDefaults(SageObject):
--- src/sage/doctest/control.py.orig 2018-10-17 17:13:36.000000000 -0600
+++ src/sage/doctest/control.py 2018-10-25 11:40:58.936908341 -0600
@@ -106,7 +106,6 @@ class DocTestDefaults(SageObject):
self.valgrind = False
self.massif = False
self.cachegrind = False
@ -9,7 +9,7 @@ diff -up src/sage/doctest/control.py.orig src/sage/doctest/control.py
self.failed = False
self.new = False
self.show_skipped = False
@@ -292,7 +291,7 @@ class DocTestController(SageObject):
@@ -308,7 +307,7 @@ class DocTestController(SageObject):
if options.gdb or options.debug:
# Interactive debuggers: "infinite" timeout
options.timeout = 0
@ -18,7 +18,7 @@ diff -up src/sage/doctest/control.py.orig src/sage/doctest/control.py
# Non-interactive debuggers: 48 hours
options.timeout = int(os.getenv('SAGE_TIMEOUT_VALGRIND', 48 * 60 * 60))
elif options.long:
@@ -1071,13 +1070,8 @@ class DocTestController(SageObject):
@@ -1094,13 +1093,8 @@ class DocTestController(SageObject):
elif opt.cachegrind:
toolname = "cachegrind"
flags = os.getenv("SAGE_CACHEGRIND_FLAGS", "")
@ -32,8 +32,8 @@ diff -up src/sage/doctest/control.py.orig src/sage/doctest/control.py
if "%s" in flags:
flags %= toolname + ".%p" # replace %s with toolname
cmd += flags + sage_cmd
@@ -1137,10 +1131,10 @@ class DocTestController(SageObject):
0
@@ -1185,10 +1179,10 @@ class DocTestController(SageObject):
"""
opt = self.options
- L = (opt.gdb, opt.valgrind, opt.massif, opt.cachegrind, opt.omega)
@ -46,20 +46,32 @@ diff -up src/sage/doctest/control.py.orig src/sage/doctest/control.py
return self.run_val_gdb()
else:
diff -up src/sage/interfaces/singular.py.orig src/sage/interfaces/singular.py
--- src/sage/interfaces/singular.py.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/sage/interfaces/singular.py 2018-08-29 08:36:07.818487766 -0600
@@ -2262,7 +2262,7 @@ def generate_docstring_dictionary():
nodes.clear()
--- src/sage/interfaces/singular.py.orig 2018-10-25 11:40:58.937908339 -0600
+++ src/sage/interfaces/singular.py 2018-10-25 13:11:10.256190334 -0600
@@ -2264,7 +2264,7 @@ def generate_docstring_dictionary():
node_names.clear()
- singular_docdir = SAGE_LOCAL+"/share/info/"
+ singular_docdir = os.environ["SINGULAR_BIN_DIR"]+"/info/"
import os
- singular_docdir = os.environ['SINGULARPATH']+"/../info/"
+ singular_docdir = "/usr/share/info/"
new_node = re.compile("File: singular\.hlp, Node: ([^,]*),.*")
new_lookup = re.compile("\* ([^:]*):*([^.]*)\..*")
new_node = re.compile(r"File: singular\.hlp, Node: ([^,]*),.*")
new_lookup = re.compile(r"\* ([^:]*):*([^.]*)\..*")
@@ -2272,8 +2272,9 @@ def generate_docstring_dictionary():
L, in_node, curr_node = [], False, None
# singular.hlp contains a few iso-5559-1 encoded special characters
- with io.open(os.path.join(singular_docdir, 'singular.hlp'),
- encoding='latin-1') as f:
+ import gzip
+ with gzip.open(os.path.join(singular_doctir, 'singular.hlp.gz'),
+ encoding='latin-1') as f:
for line in f:
m = re.match(new_node,line)
if m:
diff -up src/sage_setup/docbuild/ext/multidocs.py.orig src/sage_setup/docbuild/ext/multidocs.py
--- src/sage_setup/docbuild/ext/multidocs.py.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage_setup/docbuild/ext/multidocs.py 2018-08-29 08:36:07.829487630 -0600
--- src/sage_setup/docbuild/ext/multidocs.py.orig 2018-10-17 17:14:18.000000000 -0600
+++ src/sage_setup/docbuild/ext/multidocs.py 2018-10-25 11:40:58.937908339 -0600
@@ -84,8 +84,11 @@ def merge_environment(app, env):
for ind in newalldoc:
# treat subdocument source as orphaned file and don't complain
@ -75,9 +87,9 @@ diff -up src/sage_setup/docbuild/ext/multidocs.py.orig src/sage_setup/docbuild/e
newcite = {}
citations = docenv.domaindata["std"]["citations"]
diff -up src/sage_setup/docbuild/__init__.py.orig src/sage_setup/docbuild/__init__.py
--- src/sage_setup/docbuild/__init__.py.orig 2018-08-03 05:10:09.000000000 -0600
+++ src/sage_setup/docbuild/__init__.py 2018-08-29 08:36:07.837487531 -0600
@@ -272,13 +272,14 @@ if NUM_THREADS > 1:
--- src/sage_setup/docbuild/__init__.py.orig 2018-10-25 11:40:58.938908336 -0600
+++ src/sage_setup/docbuild/__init__.py 2018-10-25 13:12:56.110881282 -0600
@@ -279,13 +279,14 @@ def build_many(target, args):
# map_async handles KeyboardInterrupt correctly. Plain map and
# apply_async does not, so don't use it.
x = pool.map_async(target, args, 1)
@ -93,4 +105,4 @@ diff -up src/sage_setup/docbuild/__init__.py.orig src/sage_setup/docbuild/__init
+ pool.terminate()
raise
return ret
else:

View file

@ -1,6 +1,6 @@
diff -up src/bin/sage.orig src/bin/sage
--- src/bin/sage.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/bin/sage 2018-08-29 08:32:06.325478480 -0600
--- src/bin/sage.orig 2018-10-17 17:13:34.000000000 -0600
+++ src/bin/sage 2018-10-24 15:19:11.805131334 -0600
@@ -26,13 +26,10 @@ usage() {
echo " file.[sage|py|spyx] -- run given .sage, .py or .spyx file"
echo " -advanced -- list all command line options"
@ -131,7 +131,7 @@ diff -up src/bin/sage.orig src/bin/sage
echo " -startuptime [module] -- display how long each component of Sage takes to"
echo " start up; optionally specify a module to get more"
echo " details about that particular module"
@@ -220,7 +152,6 @@ usage_advanced() {
@@ -223,7 +155,6 @@ usage_advanced() {
echo " -coverage <files> -- give info about doctest coverage of files"
echo " -coverageall -- give summary info about doctest coverage of all"
echo " files in the Sage library"
@ -139,7 +139,7 @@ diff -up src/bin/sage.orig src/bin/sage
echo " -search_src <string> -- search through all the Sage library code for string"
echo " -search_doc <string> -- search through the Sage documentation for string"
echo " -grep <string> -- same as -search_src"
@@ -244,16 +175,6 @@ usage_advanced() {
@@ -249,16 +180,6 @@ usage_advanced() {
echo
#### 1.......................26..................................................78
#### |.....................--.|...................................................|
@ -156,7 +156,7 @@ diff -up src/bin/sage.orig src/bin/sage
echo "Valgrind memory debugging:"
echo " -cachegrind -- run Sage using Valgrind's cachegrind tool. The log"
echo " files are named sage-cachegrind.PID can be found in"
@@ -267,9 +188,6 @@ usage_advanced() {
@@ -272,9 +193,6 @@ usage_advanced() {
echo " -memcheck -- run Sage using Valgrind's memcheck tool. The log"
echo " files are named sage-memcheck.PID can be found in"
echo " $DOT_SAGE"
@ -166,7 +166,7 @@ diff -up src/bin/sage.orig src/bin/sage
echo " -valgrind -- this is an alias for -memcheck"
echo
echo "You can also use -- before a long option, e.g., 'sage --optional'."
@@ -279,115 +197,6 @@ usage_advanced() {
@@ -284,115 +202,6 @@ usage_advanced() {
#####################################################################
@ -282,7 +282,7 @@ diff -up src/bin/sage.orig src/bin/sage
# Report information about the Sage environment
#####################################################################
@@ -416,35 +225,8 @@ if [ $# -gt 0 ]; then
@@ -421,35 +230,8 @@ if [ $# -gt 0 ]; then
fi
@ -318,7 +318,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [ ! -d "$IPYTHONDIR" ]; then
# make sure that $DOT_SAGE exists so that ipython will happily
# create its config directories there. If DOT_SAGE doesn't
@@ -455,20 +237,6 @@ sage_setup() {
@@ -460,20 +242,6 @@ sage_setup() {
}
@ -339,7 +339,7 @@ diff -up src/bin/sage.orig src/bin/sage
# Start an interactive Sage session, this function never returns.
interactive_sage() {
sage_setup
@@ -552,16 +320,6 @@ if [ "$1" = '-lisp' -o "$1" = '--lisp' ]
@@ -557,16 +325,6 @@ if [ "$1" = '-lisp' -o "$1" = '--lisp' ]
exec ecl "$@"
fi
@ -356,8 +356,8 @@ diff -up src/bin/sage.orig src/bin/sage
if [ "$1" = '-maxima' -o "$1" = '--maxima' ]; then
shift
exec maxima "$@"
@@ -587,11 +345,6 @@ if [ "$1" = '-pip' -o "$1" = '--pip' ];
exec pip "$@"
@@ -592,11 +350,6 @@ if [ "$1" = '-pip' -o "$1" = '--pip' ];
exec sage-python23 -m pip "$@"
fi
-if [ "$1" = '-fix-pkg-checksums' -o "$1" = '--fix-pkg-checksums' ]; then
@ -368,7 +368,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [ "$1" = '-python' -o "$1" = '--python' ]; then
shift
if [ "$SAGE_PYTHON3" = 'yes' ]; then
@@ -626,16 +379,6 @@ if [ "$1" = '-ipython3' -o "$1" = '--ipy
@@ -631,16 +384,6 @@ if [ "$1" = '-ipython3' -o "$1" = '--ipy
exec ipython3 "$@"
fi
@ -385,7 +385,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [ "$1" = '-sh' -o "$1" = '--sh' ]; then
# AUTHORS:
# - Carl Witty and William Stein: initial version
@@ -755,20 +498,6 @@ EOF
@@ -760,20 +503,6 @@ EOF
fi
#####################################################################
@ -406,7 +406,7 @@ diff -up src/bin/sage.orig src/bin/sage
# File conversion
#####################################################################
@@ -796,11 +525,6 @@ fi
@@ -804,11 +533,6 @@ fi
# Run Sage's versions of the standard Algebra/Geometry etc. software
#####################################################################
@ -418,7 +418,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [[ "$1" =~ ^--notebook=.* || "$1" =~ ^-n=.* || "$1" =~ ^-notebook=.* ]] ; then
sage-cleaner &>/dev/null &
exec sage-notebook "$@"
@@ -811,13 +535,6 @@ if [ "$1" = "-notebook" -o "$1" = '--not
@@ -819,13 +543,6 @@ if [ "$1" = "-notebook" -o "$1" = '--not
exec sage-notebook "$@"
fi
@ -432,7 +432,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [ "$1" = "-inotebook" -o "$1" = '--inotebook' ]; then
shift
sage-cleaner &>/dev/null &
@@ -836,34 +553,15 @@ if [ "$1" = '-grepdoc' -o "$1" = "--grep
@@ -844,34 +561,15 @@ if [ "$1" = '-grepdoc' -o "$1" = "--grep
exit 0
fi
@ -469,7 +469,7 @@ diff -up src/bin/sage.orig src/bin/sage
shift
exec sage-runtests -p "$@"
else
@@ -872,10 +570,7 @@ if [ "$1" = '-t' -o "$1" = '-bt' -o "$1"
@@ -880,10 +578,7 @@ if [ "$1" = '-t' -o "$1" = '-bt' -o "$1"
fi
fi
@ -481,7 +481,7 @@ diff -up src/bin/sage.orig src/bin/sage
shift
sage_setup
export PYTHONIOENCODING="utf-8" # Fix encoding for doctests
@@ -896,122 +591,6 @@ if [ "$1" = '-c' ]; then
@@ -904,122 +599,6 @@ if [ "$1" = '-c' ]; then
exec sage-eval "$@"
fi
@ -604,7 +604,7 @@ diff -up src/bin/sage.orig src/bin/sage
if [ "$1" = '-gdb' -o "$1" = "--gdb" ]; then
shift
sage_setup
@@ -1061,12 +640,6 @@ if [ "$1" = '-callgrind' -o "$1" = "--ca
@@ -1069,12 +648,6 @@ if [ "$1" = '-callgrind' -o "$1" = "--ca
exec sage-callgrind "$@"
fi
@ -618,9 +618,9 @@ diff -up src/bin/sage.orig src/bin/sage
exec sage-startuptime.py "$@"
fi
diff -up src/bin/sage-runtests.orig src/bin/sage-runtests
--- src/bin/sage-runtests.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/bin/sage-runtests 2018-08-29 08:27:37.703807389 -0600
@@ -67,10 +67,6 @@ if __name__ == "__main__":
--- src/bin/sage-runtests.orig 2018-10-17 17:13:34.000000000 -0600
+++ src/bin/sage-runtests 2018-10-24 15:19:11.805131334 -0600
@@ -76,10 +76,6 @@ if __name__ == "__main__":
help="run doctests using Valgrind's cachegrind tool. The log "
"files are named sage-cachegrind.PID and can be found in " +
os.path.join(DOT_SAGE, "valgrind"))
@ -632,8 +632,8 @@ diff -up src/bin/sage-runtests.orig src/bin/sage-runtests
parser.add_option("-f", "--failed", action="store_true", default=False,
help="doctest only those files that failed in the previous run")
diff -up src/bin/sage-valgrind.orig src/bin/sage-valgrind
--- src/bin/sage-valgrind.orig 2018-08-03 05:10:08.000000000 -0600
+++ src/bin/sage-valgrind 2018-08-29 08:27:37.703807389 -0600
--- src/bin/sage-valgrind.orig 2018-10-17 17:13:34.000000000 -0600
+++ src/bin/sage-valgrind 2018-10-24 15:19:11.805131334 -0600
@@ -1,16 +1,6 @@
#!/usr/bin/env bash

View file

@ -1,6 +1,6 @@
%global __provides_exclude_from .*/site-packages/.*\\.so
# This package install python files in nonstandard places
# This package installs python files in nonstandard places
%global _python_bytecompile_extra 0
%bcond_with bundled_pexpect
@ -44,21 +44,21 @@
%global flintqs_pkg flintqs-1.0
%global graphs_pkg graphs-20161026
%if %{with bundled_ipython}
%global ipython_pkg ipython-5.5.0
%global ipython_pkg ipython-5.8.0
%endif
%if %{with bundled_ipywidgets}
%global ipywidgets_pkg ipywidgets-7.2.0
%endif
%if %{with bundled_pexpect}
%global pexpect_pkg pexpect-4.1.0
%global pexpect_pkg pexpect-4.6.0
%endif
%global polytopes_db_pkg polytopes_db-20170220
%global rubiks_pkg rubiks-20070912
%global sagenb_pkg sagenb-1.0.3
%global sagenb_export_pkg sagenb_export-3.2
%global sagetex_pkg sagetex-3.0
%global Sphinx_pkg Sphinx-1.7.5
%global singular_pkg singular-4.1.0p3
%global Sphinx_pkg Sphinx-1.7.6
%global singular_pkg singular-4.1.1p3
%if %{with bundled_thebe}
%global thebe_pkg thebe-9624e0a0
%endif
@ -72,7 +72,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.69 saclib-2.2.6 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 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_ROOT %{_libdir}/sagemath
%global SAGE_LOCAL %{SAGE_ROOT}/local
@ -85,7 +85,7 @@
Name: sagemath
Summary: A free open-source mathematics software system
Version: 8.3
Version: 8.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
@ -97,9 +97,6 @@ Source1: gprc.expect
# Follow maxima's ExclusiveArch
ExclusiveArch: aarch64 %{arm} %{ix86} x86_64 ppc sparcv9
# Upstream uses mpir not gmp, but the rpm package is tailored to use gmp
Patch1: %{name}-gmp.patch
# Set of patches to work with system wide packages
Patch2: %{name}-scripts.patch
@ -140,11 +137,17 @@ Patch10: %{name}-jmol.patch
# FIXME actually it should be already available in pari-elldata
Patch11: %{name}-cremona.patch
# adapt to python 3 and cython running in python 3 mode
Patch12: %{name}-python3.patch
# correct path to the nauty geng program
# http://cs.anu.edu.au/~bdm/nauty/
# http://pallini.di.uniroma1.it/
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
@ -174,21 +177,19 @@ Patch22: %{name}-qepcad.patch
# Correct path to arb headers
Patch23: %{name}-arb.patch
# No support for f" notation
Patch24: %{name}-nofstring.patch
# Add missing escapes, or convert strings to raw strings
Patch24: %{name}-escape.patch
# Add missing include paths
Patch25: %{name}-includes.patch
# Use atlas blas
Patch26: %{name}-atlas.patch
# Use openblas
Patch26: %{name}-openblas.patch
# Adapt to recent versions of eclib
Patch27: %{name}-eclib.patch
BuildRequires: gdb
BuildRequires: 4ti2
BuildRequires: arb-devel
BuildRequires: atlas-devel
BuildRequires: boost-devel
BuildRequires: brial-devel
BuildRequires: cddlib-tools
@ -231,8 +232,10 @@ BuildRequires: jsmol
BuildRequires: L-function-devel
BuildRequires: lapack-devel
BuildRequires: latte-integrale
BuildRequires: libbraiding-devel
BuildRequires: libfplll-devel
BuildRequires: libgap-devel
BuildRequires: libhomfly-devel
BuildRequires: libmpc-devel
BuildRequires: libpng-devel
BuildRequires: linbox-devel
@ -245,6 +248,7 @@ BuildRequires: maxima-runtime-ecl
BuildRequires: mpfi-devel
BuildRequires: nauty
BuildRequires: ntl-devel
BuildRequires: openblas-devel
BuildRequires: openssl
BuildRequires: palp
BuildRequires: pari-devel
@ -254,77 +258,74 @@ BuildRequires: pari-seadata
BuildRequires: planarity-devel
BuildRequires: ppl-devel
BuildRequires: pynac-devel
BuildRequires: python2-devel
%if %{with bundled_ipython}
BuildRequires: python2-backports-shutil_get_terminal_size
%endif
BuildRequires: python2-brial
BuildRequires: python3-devel
BuildRequires: python3-cypari2-devel
BuildRequires: python3-cysignals-devel
BuildRequires: python3-pillow-devel
BuildRequires: python3dist(brial)
%if %{with sphinx_hack}
BuildRequires: python2-configparser
BuildRequires: python3dist(configparser)
%endif
BuildRequires: python2-cypari2-devel
BuildRequires: python2-cysignals-devel
BuildRequires: python2-Cython
BuildRequires: python2-crypto
BuildRequires: python2-cryptominisat
BuildRequires: python2-cvxopt
BuildRequires: python2-docutils
BuildRequires: python2-flask-autoindex
BuildRequires: python2-flask-babel
BuildRequires: python2-flask-openid
BuildRequires: python2-flask-silk
BuildRequires: python2-fpylll
BuildRequires: python2-future
BuildRequires: python2-gmpy2
BuildRequires: python3dist(cvxopt)
BuildRequires: python3dist(cython)
BuildRequires: python3dist(docutils)
BuildRequires: python3dist(flask-autoindex)
BuildRequires: python3dist(flask-babel)
BuildRequires: python3dist(flask-openid)
BuildRequires: python3dist(flask-silk)
BuildRequires: python3dist(fpylll)
BuildRequires: python3dist(future)
BuildRequires: python3dist(gmpy2)
%if %{with sphinx_hack}
BuildRequires: python2-html5lib
BuildRequires: python2-imagesize
BuildRequires: python3dist(html5lib)
BuildRequires: python3dist(imagesize)
%endif
BuildRequires: python2-ipykernel
BuildRequires: python3dist(ipykernel)
%if %{without bundled_ipython}
BuildRequires: python2-ipython
BuildRequires: python3dist(ipython)
%endif
BuildRequires: python2-matplotlib
BuildRequires: python2-networkx
BuildRequires: python2-notebook
BuildRequires: python3dist(kiwisolver)
BuildRequires: python3dist(matplotlib)
BuildRequires: python3dist(networkx)
BuildRequires: python3dist(notebook)
%if %{with bundled_ipython}
BuildRequires: python2-path
BuildRequires: python3dist(path.py)
%endif
BuildRequires: python2-pathlib2
BuildRequires: python3dist(pathlib2)
%if %{without bundled_pexpect}
BuildRequires: python2-pexpect
BuildRequires: python3dist(pexpect)
%endif
BuildRequires: python2-pickleshare
BuildRequires: python2-pillow-devel
BuildRequires: python2-pip
BuildRequires: python2-prompt_toolkit
BuildRequires: python2-pkgconfig
BuildRequires: python2-psutil
BuildRequires: python2-ptyprocess
BuildRequires: python2-scipy
BuildRequires: python2-send2trash
BuildRequires: python2-setuptools
BuildRequires: python3dist(pickleshare)
BuildRequires: python3dist(pip)
BuildRequires: python3dist(prompt-toolkit)
BuildRequires: python3dist(pkgconfig)
BuildRequires: python3dist(psutil)
BuildRequires: python3dist(ptyprocess)
BuildRequires: python3dist(pycryptosat)
%if %{with bundled_ipython}
BuildRequires: python2-simplegeneric
BuildRequires: python3dist(pyzmq)
%endif
BuildRequires: python2-six
BuildRequires: python2-speaklater
BuildRequires: python2-sphinx
BuildRequires: python2-sympy
BuildRequires: python2-twisted
BuildRequires: python3dist(rpy2)
BuildRequires: python3dist(scipy)
BuildRequires: python3dist(scons)
BuildRequires: python3dist(send2trash)
BuildRequires: python3dist(setuptools)
%if %{with bundled_ipython}
BuildRequires: python2-zmq
BuildRequires: python3dist(simplegeneric)
%endif
BuildRequires: python2-ZODB3
BuildRequires: python3-Cython
BuildRequires: python3dist(six)
BuildRequires: python3dist(speaklater)
BuildRequires: python3dist(sphinx)
BuildRequires: python3dist(sympy)
BuildRequires: python3dist(twisted)
BuildRequires: python3dist(zodb3)
BuildRequires: qepcad-B
BuildRequires: R
BuildRequires: ratpoints-devel
BuildRequires: readline-devel
BuildRequires: rpy
BuildRequires: rw-devel
BuildRequires: scons
BuildRequires: Singular-devel
BuildRequires: sirocco-devel
BuildRequires: stix-math-fonts
BuildRequires: symmetrica-devel
BuildRequires: sympow
@ -368,67 +369,64 @@ Requires: palp
Requires: pari-galdata
Requires: pari-gp
Requires: pari-seadata
%if %{with bundled_ipython}
Requires: python2-backports-shutil_get_terminal_size
%endif
Requires: python2-brial
Requires: python3dist(brial)
%if %{with sphinx_hack}
Requires: python2-configparser
Requires: python3dist(configparser)
%endif
Requires: python2-cypari2
Requires: python2-cysignals
Requires: python2-crypto
Requires: python2-cryptominisat
Requires: python2-cvxopt
Requires: python2-Cython
Requires: python2-docutils
Requires: python2-flask-autoindex
Requires: python2-flask-babel
Requires: python2-flask-openid
Requires: python2-flask-silk
Requires: python2-fpylll
Requires: python2-future
Requires: python2-gmpy2
Requires: python3dist(cypari2)
Requires: python3dist(cysignals)
Requires: python3dist(cvxopt)
Requires: python3dist(cython)
Requires: python3dist(docutils)
Requires: python3dist(flask-autoindex)
Requires: python3dist(flask-babel)
Requires: python3dist(flask-openid)
Requires: python3dist(flask-silk)
Requires: python3dist(fpylll)
Requires: python3dist(future)
Requires: python3dist(gmpy2)
%if %{with sphinx_hack}
Requires: python2-html5lib
Requires: python2-imagesize
Requires: python3dist(html5lib)
Requires: python3dist(imagesize)
%endif
Requires: python2-ipykernel
Requires: python3dist(ipykernel)
%if %{without bundled_ipython}
Requires: python2-ipython
Requires: python3dist(ipython)
%endif
Requires: python2-matplotlib
Requires: python2-networkx
Requires: python2-notebook
Requires: python3dist(kiwisolver)
Requires: python3dist(matplotlib)
Requires: python3dist(networkx)
Requires: python3dist(notebook)
%if %{with bundled_ipython}
Requires: python2-path
Requires: python3dist(path)
%endif
Requires: python2-pathlib2
Requires: python3dist(pathlib2)
%if %{without bundled_pexpect}
Requires: python2-pexpect
Requires: python3dist(pexpect)
%endif
Requires: python2-pickleshare
Requires: python2-pillow
Requires: python2-prompt_toolkit
Requires: python2-psutil
Requires: python2-ptyprocess
Requires: python2-scipy
Requires: python2-send2trash
Requires: python3dist(pickleshare)
Requires: python3dist(pillow)
Requires: python3dist(prompt-toolkit)
Requires: python3dist(psutil)
Requires: python3dist(ptyprocess)
Requires: python3dist(pycryptosat)
Requires: python3dist(rpy2)
Requires: python3dist(scipy)
Requires: python3dist(send2trash)
%if %{with bundled_ipython}
BuildRequires: python2-simplegeneric
BuildRequires: python3dist(simplegeneric)
%endif
Requires: python2-six
Requires: python2-speaklater
Requires: python2-sphinx
Requires: python2-sympy
Requires: python2-twisted
Requires: python3dist(six)
Requires: python3dist(speaklater)
Requires: python3dist(sphinx)
Requires: python3dist(sympy)
Requires: python3dist(twisted)
%if %{with bundled_ipython}
Requires: python2-zmq
Requires: python3dist(zmq)
%endif
Requires: python2-ZODB3
Requires: python3dist(zodb3)
Requires: qepcad-B
Requires: R
Requires: rpy
Requires: %{name}-core
Requires: %{name}-data
%if %{with docs}
@ -825,7 +823,6 @@ pushd build/pkgs/widgetsnbextension
popd
%endif
%patch1
%patch2
%patch3
%patch4
@ -836,7 +833,9 @@ popd
%patch9
%patch10
%patch11
%patch12
%patch13
%patch14
%patch15
%patch16
%patch17
@ -854,13 +853,13 @@ popd
%patch24
%patch25
%patch26
%patch27
sed -e 's|@@SAGE_ROOT@@|%{SAGE_ROOT}|' \
-e 's|@@SAGE_DOC@@|%{SAGE_DOC}|' \
-i src/sage/env.py
sed -e 's|@@CYSIGNALS@@|%{python2_sitearch}/cysignals|' \
sed -e 's|@@CYSIGNALS@@|%{python3_sitearch}/cysignals|' \
-e 's|@@BUILDROOT@@|%{buildroot}|' \
-i src/setup.py
sed -e "/flask-oldsessions/d" \
@ -886,31 +885,39 @@ sed -e "s,\(SINGULAR_SO = \)SAGE.*,\1'%{_libdir}/libSingular-$singver.so'," \
# fix shebangs; some paths contains spaces, so use the null byte facility
grep -FrlZ '#!%{_bindir}/env python' | \
xargs -0 sed -i 's,#!%{_bindir}/env python,#!%{__python2},'
xargs -0 sed -i 's,#!%{_bindir}/env python,#!%{__python3},'
grep -FrlZ '#!%{_bindir}/env sage-python23' | \
xargs -0 sed -i 's,#!%{_bindir}/env sage-python23,#!%{__python2},'
xargs -0 sed -i 's,#!%{_bindir}/env 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$,&2,'
sed -i 's,%{_bindir}/env python,%{__python2},' \
grep -rlZ '#!%{_bindir}/python$' | xargs -0 sed -i 's,#!%{_bindir}/python$,&3,'
sed -i 's,%{_bindir}/env python,%{__python3},' \
%if %{with bundled_pexpect}
build/pkgs/pexpect/src/examples/python.py \
%endif
build/pkgs/sagetex/src/sagetex.ins
sed -i 's,%{_bindir}/python,&2,' src/sage/misc/dev_tools.py
sed -i 's,%{_bindir}/python,&3,' src/sage/misc/dev_tools.py
sed -e 's,local/bin/python,bin/python,' \
-e 's,#!%{_bindir}/python,&2,' \
-e 's,#!%{_bindir}/python,&3,' \
-i src/sage/repl/preparse.py
%if %{with bundled_ipython}
sed -e "s|'%{_bindir}/env', 'which'|'%{_bindir}/which'|" \
-i build/pkgs/ipython/src/IPython/utils/_process_posix.py
%endif
# fix path to pip for python 3
sed -i 's/"pip",/"pip3",/' src/sage/misc/package.py
# GAP does not have enough memory to load the entire workspace
sed -i 's/64m/128m/' src/sage/libs/gap/util.pyx
########################################################################
%build
export CC=%{__cc}
export CFLAGS="%{optflags}"
export CXXFLAGS="%{optflags}"
export SAGE_PYTHON_VERSION=3
export SAGE_ROOT=%{buildroot}%{SAGE_ROOT}
export SAGE_LOCAL=%{buildroot}%{SAGE_LOCAL}
# Avoid buildroot in gcc command line (use _builddir instead)
@ -934,8 +941,8 @@ ln -sf %{_includedir} $SAGE_LOCAL/include
ln -sf %{_datadir} $SAGE_LOCAL/share
export PATH=%{buildroot}%{_bindir}:$PATH
export PYTHON=%{_bindir}/python2
export PYTHONPATH=%{buildroot}%{python2_sitearch}:$PYTHONPATH
export PYTHON=%{_bindir}/python3
export PYTHONPATH=%{buildroot}%{python3_sitearch}:$PYTHONPATH
#------------------------------------------------------------------------
# Save and update environment to generate bundled interfaces
@ -946,29 +953,29 @@ export SAGE_LOCAL=%{_builddir}
%if %{with bundled_ipython}
pushd build/pkgs/ipython/src
%__python2 setup.py build
%__python2 setup.py install --root %{_builddir}
%__python3 setup.py build
%__python3 setup.py install --root %{_builddir}
popd
%endif
%if %{with bundled_ipywidgets}
pushd build/pkgs/ipywidgets/src
%__python2 setup.py build
%__python2 setup.py install --root %{_builddir}
%__python3 setup.py build
%__python3 setup.py install --root %{_builddir}
popd
%endif
%if %{with bundled_widgetsnbextension}
pushd build/pkgs/widgetsnbextension/src
%__python2 setup.py build
%__python2 setup.py install --root %{_builddir}
%__python3 setup.py build
%__python3 setup.py install --root %{_builddir}
popd
%endif
%if %{with cython_hack}
cp -far %{python2_sitearch}/Cython %{_builddir}%{python2_sitearch}
cp -far %{python3_sitearch}/Cython %{_builddir}%{python3_sitearch}
BASE=$PWD/build/pkgs/cython/patches/
pushd %{_builddir}%{python2_sitearch}
pushd %{_builddir}%{python3_sitearch}
for PATCH in pxi_sys_path.patch
do
patch -p1 < $BASE/$PATCH
@ -983,16 +990,16 @@ mkdir -p %{buildroot}%{SAGE_SPKG_INST}
mkdir -p %{buildroot}%{_libdir}/sagemath/build/pkgs
pushd src
%__python2 -u ./setup.py build
%__python3 -u ./setup.py build
popd
#------------------------------------------------------------------------
pushd build/pkgs/sagenb/src
%__python2 ./setup.py build
%__python3 ./setup.py build
popd
pushd build/pkgs/sagenb_export/src
%__python2 ./setup.py build
%__python3 ./setup.py build
popd
#------------------------------------------------------------------------
@ -1005,16 +1012,6 @@ pushd build/pkgs/rubiks/src
make %{?_smp_mflags} CC="gcc -fPIC" CXX="g++ -fPIC" CFLAGS="%{optflags}" CXXFLAGS="%{optflags}"
popd
# 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
%__python2 ./setup.py build
popd
# last build command
rm -fr $DOT_SAGE
@ -1039,9 +1036,9 @@ export DOT_SAGE=/tmp/sage$$
mkdir -p $DOT_SAGE/tmp
export PATH=%{buildroot}%{_bindir}:$PATH
export PYTHON=%{_bindir}/python2
export PYTHONPATH=%{buildroot}%{python2_sitearch}:$PYTHONPATH
export PYTHONPATH=%{_builddir}%{python2_sitearch}:$PYTHONPATH
export PYTHON=%{_bindir}/python3
export PYTHONPATH=%{buildroot}%{python3_sitearch}:$PYTHONPATH
export PYTHONPATH=%{_builddir}%{python3_sitearch}:$PYTHONPATH
#------------------------------------------------------------------------
mkdir -p %{buildroot}%{_bindir}
@ -1076,10 +1073,10 @@ popd
#------------------------------------------------------------------------
pushd src
%if %{without install_hack}
%py2_install
%py3_install
%else
mkdir -p %{buildroot}%{python2_sitearch}
cp -far build/lib.linux-*/sage %{buildroot}%{python2_sitearch}
mkdir -p %{buildroot}%{python3_sitearch}
cp -far build/lib.linux-*/sage %{buildroot}%{python3_sitearch}
%endif
%if %{with docs}
# install documentation sources
@ -1090,23 +1087,23 @@ popd
#------------------------------------------------------------------------
pushd build/pkgs/sagenb/src
rm -f %{buildroot}%{python2_sitearch}/sagenb/data/sage3d/sage3d
%py2_install "--install-purelib=%{python2_sitearch}"
rm -f %{buildroot}%{python3_sitearch}/sagenb/data/sage3d/sage3d
%py3_install "--install-purelib=%{python3_sitearch}"
# jsmol
ln -sf %{_jsdir}/jsmol $SAGE_SHARE/jsmol
# sage3d
rm -f %{buildroot}%{_bindir}/sage3d
%if %{with sage3d}
ln -sf %{SAGE_LOCAL}/bin/sage3d %{buildroot}%{python2_sitearch}/sagenb/data/sage3d/sage3d
ln -sf %{SAGE_LOCAL}/bin/sage3d %{buildroot}%{python3_sitearch}/sagenb/data/sage3d/sage3d
%endif
ln -sf %{python2_sitearch}/sagenb %{buildroot}%{SAGE_SRC}/sagenb
ln -sf %{python3_sitearch}/sagenb %{buildroot}%{SAGE_SRC}/sagenb
# use system mathjax
ln -sf %{_jsdir}/mathjax %{buildroot}%{python2_sitearch}/sagenb/data/mathjax
ln -sf %{_jsdir}/mathjax %{buildroot}%{python3_sitearch}/sagenb/data/mathjax
popd
#------------------------------------------------------------------------
pushd build/pkgs/sagenb_export/src
%py2_install
%py3_install
popd
#------------------------------------------------------------------------
@ -1123,8 +1120,8 @@ pushd src/bin
cp -fa sage-* $SAGE_LOCAL/bin
pushd $SAGE_LOCAL/bin
ln -sf %{_bindir}/jmol jmol
ln -sf %{_bindir}/python sage.bin
ln -sf %{_bindir}/python python
ln -sf %{_bindir}/python3 sage.bin
ln -sf %{_bindir}/python3 python
ln -sf %{_bindir}/gp sage_pari
ln -sf %{_bindir}/gap gap
ln -sf %{_bindir}/gmp-ecm ecm
@ -1200,7 +1197,7 @@ popd
#------------------------------------------------------------------------
pushd build/pkgs/conway_polynomials
%__python2 ./spkg-install.py
%__python3 ./spkg-install.py
popd
#------------------------------------------------------------------------
@ -1211,7 +1208,7 @@ pushd build/pkgs/elliptic_curves
tar jxf ../../../upstream/%{elliptic_curves_pkg}.tar.bz2
mv %{elliptic_curves_pkg} src
fi
%__python2 ./spkg-install.py
%__python3 ./spkg-install.py
popd
#------------------------------------------------------------------------
@ -1228,7 +1225,7 @@ popd
#------------------------------------------------------------------------
pushd build/pkgs/sagetex/src
%py2_install "--install-purelib=%{python2_sitearch}"
%py3_install "--install-purelib=%{python3_sitearch}"
mv %{buildroot}%{_texmf_main}/tex/latex/sagetex/CONTRIBUTORS \
%{buildroot}%{_docdir}/sagetex
for file in PKG-INFO README; do
@ -1238,13 +1235,13 @@ popd
#------------------------------------------------------------------------
%if %{with bundled_ipython}
mv %{_builddir}%{python2_sitelib}/IPython %{buildroot}%{SAGE_PYTHONPATH}
mv %{_builddir}%{python3_sitelib}/IPython %{buildroot}%{SAGE_PYTHONPATH}
mv %{_builddir}%{_bindir}/ip* %{buildroot}%{SAGE_LOCAL}/bin
%endif
#------------------------------------------------------------------------
%if %{with bundled_ipywidgets}
mv %{_builddir}%{python2_sitelib}/ipywidgets %{buildroot}%{SAGE_PYTHONPATH}
mv %{_builddir}%{python3_sitelib}/ipywidgets %{buildroot}%{SAGE_PYTHONPATH}
%endif
#------------------------------------------------------------------------
@ -1265,7 +1262,7 @@ popd
#------------------------------------------------------------------------
%if %{with bundled_widgetsnbextension}
pushd build/pkgs/widgetsnbextension/src
%py2_install "--install-purelib=%{python2_sitelib}"
%py3_install "--install-purelib=%{python3_sitelib}"
mv %{buildroot}%{_prefix}%{_sysconfdir} %{buildroot}%{_sysconfdir}
popd
%endif
@ -1324,17 +1321,17 @@ chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage3d
# o install .pxi and .pxd files
pushd src
for f in `find sage \( -name \*.pxi -o -name \*.pxd -o -name \*.pyx \)`; do
install -p -D -m 0644 $f %{buildroot}%{python2_sitearch}/$f
install -p -D -m 0644 $f %{buildroot}%{python3_sitearch}/$f
done
# need this or will not "find" the files in the directory, and
# fail to link with gmp
touch %{buildroot}%{python2_sitearch}/sage/libs/gmp/__init__.py
touch %{buildroot}%{python3_sitearch}/sage/libs/gmp/__init__.py
popd
%if %{with docs}
#------------------------------------------------------------------------
%if %{with bundled_pexpect}
cp -fa $SAGE_PYTHONPATH/pexpect %{buildroot}%{python2_sitearch}
cp -fa $SAGE_PYTHONPATH/pexpect %{buildroot}%{python3_sitearch}
%endif
# Build documentation, using %#{buildroot} environment
@ -1344,13 +1341,12 @@ pushd src/doc
export PATH=%{buildroot}%{_bindir}:$SAGE_LOCAL/bin:$PATH
export SINGULARPATH=%{_datadir}/singular/LIB
export SINGULAR_BIN_DIR=%{_libdir}/Singular
export LD_LIBRARY_PATH=%{_libdir}/atlas:$LD_LIBRARY_PATH
export PYTHONPATH=$SAGE_SETUP:%{buildroot}%{python2_sitearch}:$SAGE_PYTHONPATH:$SAGE_DOC
export PYTHONPATH=$SAGE_SETUP:%{buildroot}%{python3_sitearch}:$SAGE_PYTHONPATH:$SAGE_DOC
%if %{with sphinx_hack}
pushd ../../build/pkgs/sphinx/src
%py2_build
%py2_install "--install-purelib=%{python2_sitearch}"
%py3_build
%py3_install "--install-purelib=%{python3_sitearch}"
rm -f %{buildroot}%{_bindir}/sphinx*
popd
%endif
@ -1362,7 +1358,7 @@ pushd src/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" \
xvfb-run -a -n 1 %__python2 -m docbuild --no-pdf-links -k all html -j
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
@ -1380,12 +1376,12 @@ sed -i 's|%{buildroot}||g' $SAGE_DOC/test.log
%endif
%if %{with bundled_pexpect}
rm -f %{buildroot}%{python2_sitearch}/pexpect
rm -f %{buildroot}%{python3_sitearch}/pexpect
%endif
%if %{with sphinx_hack}
rm -fr %{buildroot}%{python2_sitearch}/sphinx \
%{buildroot}%{python2_sitearch}/Sphinx*
rm -fr %{buildroot}%{python3_sitearch}/sphinx \
%{buildroot}%{python3_sitearch}/Sphinx*
%endif
# More wrong buildroot references
@ -1403,8 +1399,8 @@ perl -pi -e 's|%{buildroot}||g;s|^##||g;' %{buildroot}%{_bindir}/sage
export SAGE_SRC=%{buildroot}%{SAGE_SRC}
rm -fr $SAGE_SRC/sage $SAGE_ETC/sage $SAGE_ROOT/doc $SAGE_SRC/doc
rm -fr $SAGE_ROOT/share $SAGE_ROOT/devel
ln -sf %{python2_sitearch}/sage $SAGE_SRC/sage
ln -sf %{python2_sitearch} $SAGE_ETC/sage
ln -sf %{python3_sitearch}/sage $SAGE_SRC/sage
ln -sf %{python3_sitearch} $SAGE_ETC/sage
ln -sf %{SAGE_DOC} $SAGE_ROOT/doc
%if %{with docs}
ln -sf %{SAGE_DOC} $SAGE_SRC/doc
@ -1452,10 +1448,10 @@ find %{buildroot}%{SAGE_DOC} -type d -name _sources -exec rm -fr {} \+
%endif
# remove .po files
rm %{buildroot}%{python2_sitearch}/sagenb/translations/*/LC_MESSAGES/*.po
rm %{buildroot}%{python3_sitearch}/sagenb/translations/*/LC_MESSAGES/*.po
%if %{without sage3d}
rm -r %{buildroot}%{python2_sitearch}/sagenb/data/sage3d
rm -r %{buildroot}%{python3_sitearch}/sagenb/data/sage3d
%endif
# remove build directory in buildroot
@ -1464,7 +1460,7 @@ rm -r %{buildroot}%{python2_sitearch}/sagenb/data/sage3d
%if %{without install_hack}
# remove sage_setup
rm -r %{buildroot}%{python2_sitearch}/sage_setup
rm -r %{buildroot}%{python3_sitearch}/sage_setup
%endif
# pretend sagemath spkgs are installed to reduce number of errors
@ -1517,7 +1513,7 @@ chmod +x %{buildroot}%{SAGE_LOCAL}/bin/sage-list-packages
#------------------------------------------------------------------------
# Byte compile python files in nonstandard places
%py_byte_compile %{__python2} %{buildroot}%{_texmf_main}/tex/latex/sagetex
%py_byte_compile %{__python3} %{buildroot}%{_texmf_main}/tex/latex/sagetex
# last install command
rm -fr $DOT_SAGE
@ -1545,6 +1541,7 @@ rm -fr $DOT_SAGE
%{SAGE_LOCAL}/include
%{SAGE_LOCAL}/lib
%{SAGE_LOCAL}/share
%{SAGE_LOCAL}/var
%{SAGE_ROOT}/doc
%{SAGE_ROOT}/devel
%{SAGE_ROOT}/share
@ -1558,7 +1555,6 @@ rm -fr $DOT_SAGE
%{_bindir}/sage
%{_datadir}/pixmaps/%{name}.png
%{_datadir}/applications/%{name}.desktop
%{SAGE_SPKG_INST}
%if %{with bundled_thebe}
# MIT
%{SAGE_SHARE}/thebe
@ -1571,9 +1567,9 @@ rm -fr $DOT_SAGE
#------------------------------------------------------------------------
%files core
# GPLv2+
%{python2_sitearch}/sage
%{python3_sitearch}/sage
%if %{without install_hack}
%{python2_sitearch}/sage-*.egg-info
%{python3_sitearch}/sage-*.egg-info
%endif
%if %{with bundled_ipython}
%{SAGE_PYTHONPATH}/IPython
@ -1587,7 +1583,7 @@ rm -fr $DOT_SAGE
%dir %{_sysconfdir}/jupyter/nbconfig/notebook.d
%config(noreplace) %{_sysconfdir}/jupyter/nbconfig/notebook.d/*.json
%{_datadir}/jupyter/
%{python2_sitelib}/widgetsnbextension*
%{python3_sitelib}/widgetsnbextension*
%endif
#------------------------------------------------------------------------
@ -1702,76 +1698,79 @@ rm -fr $DOT_SAGE
%{SAGE_ETC}/notebook-ipython
# GPLv2+
%{SAGE_SRC}/sagenb
%dir %{python2_sitearch}/sagenb
%{python2_sitearch}/sagenb/*.py*
%{python2_sitearch}/sagenb-*.egg-info
%dir %{python2_sitearch}/sagenb/data
%dir %{python3_sitearch}/sagenb
%{python3_sitearch}/sagenb/*.py*
%{python3_sitearch}/sagenb/__pycache__/
%{python3_sitearch}/sagenb/data/__pycache__/
%{python3_sitearch}/sagenb/testing/__pycache__/
%{python3_sitearch}/sagenb-*.egg-info
%dir %{python3_sitearch}/sagenb/data
# BSD
%{python2_sitearch}/sagenb/data/codemirror
%{python3_sitearch}/sagenb/data/codemirror
# MIT
%{python2_sitearch}/sagenb/data/graph_editor
%{python3_sitearch}/sagenb/data/graph_editor
# ASL 2.0
%{python2_sitearch}/sagenb/data/highlight
%{python3_sitearch}/sagenb/data/highlight
# LGPLv2+
%{SAGE_SHARE}/jsmol
# (MIT or GPLv2) and (MIT and BSD and GPL)
%{python2_sitearch}/sagenb/data/jquery
%{python3_sitearch}/sagenb/data/jquery
# (MIT or GPLv2) and (MIT and BSD and GPL)
%{python2_sitearch}/sagenb/data/jqueryui
%{python3_sitearch}/sagenb/data/jqueryui
# Public Domain
%{python2_sitearch}/sagenb/data/json
%{python3_sitearch}/sagenb/data/json
# Symbolic link to $_jsdir/mathjax
%{python2_sitearch}/sagenb/data/mathjax
%ghost %{python2_sitearch}/sagenb/data/mathjax.rpmmoved
%{python3_sitearch}/sagenb/data/mathjax
%ghost %{python3_sitearch}/sagenb/data/mathjax.rpmmoved
# Empty (do not run doctests flag file)
%{python2_sitearch}/sagenb/data/nodoctest.py*
%{python3_sitearch}/sagenb/data/nodoctest.py*
# BSD
%{python2_sitearch}/sagenb/data/openid-realselector
%{python3_sitearch}/sagenb/data/openid-realselector
# GPLv2+
%{python2_sitearch}/sagenb/data/sage
%{python3_sitearch}/sagenb/data/sage
%if %{with sage3d}
# GPLv2+
%{python2_sitearch}/sagenb/data/sage3d
%{python3_sitearch}/sagenb/data/sage3d
%endif
# LGPLv2+
%{python2_sitearch}/sagenb/data/tiny_mce
%{python3_sitearch}/sagenb/data/tiny_mce
# LGPLv2+
%{python2_sitearch}/sagenb/data/zorn
%{python3_sitearch}/sagenb/data/zorn
# GPLv2+
%{python2_sitearch}/sagenb/flask_version
%{python3_sitearch}/sagenb/flask_version
# GPLv2+
%{python2_sitearch}/sagenb/interfaces
%{python3_sitearch}/sagenb/interfaces
# GPLv2+
%{python2_sitearch}/sagenb/misc
%{python3_sitearch}/sagenb/misc
# GPLv2+
%{python2_sitearch}/sagenb/notebook
%{python3_sitearch}/sagenb/notebook
# GPLv2+
%{python2_sitearch}/sagenb/simple
%{python3_sitearch}/sagenb/simple
# GPLv2+
%{python2_sitearch}/sagenb/storage
%{python3_sitearch}/sagenb/storage
# GPLv2+
%dir %{python2_sitearch}/sagenb/testing
%{python2_sitearch}/sagenb/testing/*.py*
%{python2_sitearch}/sagenb/testing/tests
%dir %{python3_sitearch}/sagenb/testing
%{python3_sitearch}/sagenb/testing/*.py*
%{python3_sitearch}/sagenb/testing/tests
# ASL 2.0
%{python2_sitearch}/sagenb/testing/selenium
%{python3_sitearch}/sagenb/testing/selenium
# GPLv2+
%dir %{python2_sitearch}/sagenb/translations
%lang(cs_CZ) %{python2_sitearch}/sagenb/translations/cs_CZ
%lang(de_AT) %{python2_sitearch}/sagenb/translations/de_AT
%lang(de_AT) %{python2_sitearch}/sagenb/translations/en_US
%lang(de_AT) %{python2_sitearch}/sagenb/translations/es_ES
%lang(de_AT) %{python2_sitearch}/sagenb/translations/fr_FR
%lang(pt_BR) %{python2_sitearch}/sagenb/translations/pt_BR
%lang(ru_RU) %{python2_sitearch}/sagenb/translations/ru_RU
%lang(uk_UA) %{python2_sitearch}/sagenb/translations/uk_UA
%dir %{python3_sitearch}/sagenb/translations
%lang(cs_CZ) %{python3_sitearch}/sagenb/translations/cs_CZ
%lang(de_AT) %{python3_sitearch}/sagenb/translations/de_AT
%lang(de_AT) %{python3_sitearch}/sagenb/translations/en_US
%lang(de_AT) %{python3_sitearch}/sagenb/translations/es_ES
%lang(de_AT) %{python3_sitearch}/sagenb/translations/fr_FR
%lang(pt_BR) %{python3_sitearch}/sagenb/translations/pt_BR
%lang(ru_RU) %{python3_sitearch}/sagenb/translations/ru_RU
%lang(uk_UA) %{python3_sitearch}/sagenb/translations/uk_UA
#------------------------------------------------------------------------
%files notebook-export
# GPL+
%{_bindir}/sagenb-export
%{python2_sitelib}/sagenb_export
%{python2_sitelib}/sagenb_export-*.egg-info
%{python3_sitelib}/sagenb_export
%{python3_sitelib}/sagenb_export-*.egg-info
#------------------------------------------------------------------------
%files rubiks
@ -1788,12 +1787,21 @@ rm -fr $DOT_SAGE
#------------------------------------------------------------------------
%files sagetex
# GPLv2+
%{python2_sitearch}/sagetex*
%{python3_sitearch}/sagetex*
%{_texmf_main}/tex/latex/sagetex
%doc %{_docdir}/sagetex
########################################################################
%changelog
* 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
- Add -python3 and -escape patches to fix problems with python 3
- Drop -nofstring patch, only needed for python 2
- Drop upstreamed -eclib patch
- Switch from atlas to openblas and rename -atlas patch to -openblas
- Add -buildroot patch and only build cython interfaces once
* Sat Sep 22 2018 Jerry James <loganjerry@gmail.com> - 8.3-1
- Update to sagemath 8.3 (bz 1612867)
- Drop -lrslib, -gap-hap, and -flask patches

View file

@ -1 +1 @@
SHA512 (sage-8.3.tar.gz) = d0b971896738adc6604e51a00ff38f41b5c2e7595e8d257346fd975106519a1b3a1734a07229e7bf6e9373073d0cc0ca45c259dece1e7c97a3debd12914485d6
SHA512 (sage-8.4.tar.gz) = 500c5005420c226993b79e89b761a3c9fe57d5ff6d6d71abedaf347ab2fd16b2f5e3b2caa660c4a0d984ba07038f9b4ffce8eb7b6cb28d2448c62d5e18acd871