sagemath/sagemath-maxima.patch
Jerry James 55beead27c Update to sagemath 8.5.
Also:
- Bundle ipython again; Fedora version is too far ahead.  Also have to bundle
  prompt_toolkit since Fedora version is too far ahead of bundled ipython.
- Drop LANGUAGES variable setting, now ignored by the sagemath build system.
- Drop unused SAGE_CBLAS variable from /usr/bin/sage.
- Do not force the C locale when launching sagemath.
- Allow the user to override SAGE_DEBUG in /usr/bin/sage.
- Add -ecm, -giac, and -latte patches to fix interactions with external tools.
- Add -sigfpe patch from upstream.
2019-01-17 19:27:08 -07: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-12-22 16:37:06.000000000 -0700
+++ src/bin/sage-maxima.lisp 2019-01-16 09:43:18.550338178 -0700
@@ -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-12-22 16:37:08.000000000 -0700
+++ src/sage/interfaces/maxima.py 2019-01-16 09:43:18.552338143 -0700
@@ -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