sagemath/sagemath-maxima.patch
Jerry James eaa777c690 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.
2018-11-01 19:25:26 -06:00

34 lines
1.8 KiB
Diff

diff -up src/bin/sage-maxima.lisp.orig src/bin/sage-maxima.lisp
--- 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>")
+#+clisp
+(setf
+ *error-output* (open "/dev/stderr" :direction :output)
+ *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-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 = r'\(\%i[0-9]+\) ',
- command = 'maxima -p "{0}"'.format(STARTUP),
+ command = 'maxima --disable-readline -p "{0}"'.format(STARTUP),
env = {'TMPDIR': str(ECL_TMP)},
script_subdirectory = script_subdirectory,
restart_on_ctrlc = False,
@@ -615,7 +615,8 @@ class Maxima(MaximaAbstract, Expect):
# Remove limit on the max heapsize (since otherwise it defaults
# to 256MB with ECL).
- self._sendline(":lisp (ext:set-limit 'ext:heap-size 0)")
+ self._sendline(":lisp #+ecl (ext:set-limit 'ext:heap-size 0) #-ecl 0")
+ self._sendline(':lisp #+gcl (progn (si:readline-off) (setf *error-output* (open "/dev/stderr" :direction :output) *standard-input* (open "/dev/stdin" :direction :input) *standard-output* (open "/dev/stdout" :direction :output))) #-gcl t')
self._eval_line('0;')
# set random seed