mirror of
https://src.fedoraproject.org/rpms/sagemath.git
synced 2025-04-22 11:45:56 -04:00
parent
d27dab46a5
commit
66bc672795
2 changed files with 66 additions and 2 deletions
54
sagemath-qepcad.patch
Normal file
54
sagemath-qepcad.patch
Normal file
|
@ -0,0 +1,54 @@
|
|||
diff -up src/sage/interfaces/qepcad.py.orig src/sage/interfaces/qepcad.py
|
||||
--- src/sage/interfaces/qepcad.py.orig 2015-07-25 19:41:13.149677325 -0300
|
||||
+++ src/sage/interfaces/qepcad.py 2015-07-25 19:42:52.372681124 -0300
|
||||
@@ -519,9 +519,8 @@ TESTS:
|
||||
|
||||
Check the qepcad configuration file::
|
||||
|
||||
- sage: from sage.misc.misc import SAGE_LOCAL
|
||||
- sage: open('%s/default.qepcadrc'%SAGE_LOCAL).readlines()[-1]
|
||||
- 'SINGULAR .../local/bin\n'
|
||||
+ sage: open('/usr/share/qepcad/default.qepcadrc').readlines()[-1]
|
||||
+ 'SINGULAR /usr/bin\n'
|
||||
|
||||
AUTHORS:
|
||||
|
||||
@@ -548,6 +547,8 @@ from sage.misc.preparser import implicit
|
||||
|
||||
from expect import Expect, ExpectFunction, AsciiArtString
|
||||
|
||||
+QEPCAD_LOCAL = "/usr/share/qepcad"
|
||||
+
|
||||
def _qepcad_cmd(memcells=None):
|
||||
r"""
|
||||
Construct a QEPCAD command line. Optionally set the
|
||||
@@ -558,17 +559,17 @@ def _qepcad_cmd(memcells=None):
|
||||
sage: from sage.interfaces.qepcad import _qepcad_cmd
|
||||
sage: from sage.misc.misc import SAGE_LOCAL
|
||||
sage: s = _qepcad_cmd()
|
||||
- sage: s == 'env qe=%s qepcad '%SAGE_LOCAL
|
||||
+ sage: s == 'env qe=/usr/share/qepcad qepcad '
|
||||
True
|
||||
sage: s = _qepcad_cmd(memcells=8000000)
|
||||
- sage: s == 'env qe=%s qepcad +N8000000'%SAGE_LOCAL
|
||||
+ sage: s == 'env qe=/usr/share/qepcad qepcad +N8000000'
|
||||
True
|
||||
"""
|
||||
if memcells is not None:
|
||||
memcells_arg = '+N%s' % memcells
|
||||
else:
|
||||
memcells_arg = ''
|
||||
- return "env qe=%s qepcad %s"%(sage.misc.misc.SAGE_LOCAL, memcells_arg)
|
||||
+ return "env qe=%s qepcad %s"%(QEPCAD_LOCAL, memcells_arg)
|
||||
|
||||
_command_info_cache = None
|
||||
|
||||
@@ -590,7 +591,7 @@ def _update_command_info():
|
||||
|
||||
cache = {}
|
||||
|
||||
- with open('%s/bin/qepcad.help'%sage.misc.misc.SAGE_LOCAL) as help:
|
||||
+ with open('%s/bin/qepcad.help'%QEPCAD_LOCAL) as help:
|
||||
assert(help.readline().strip() == '@')
|
||||
|
||||
while True:
|
Loading…
Add table
Add a link
Reference in a new issue