sagemath/sagemath-libgap.patch
2015-04-03 20:10:52 -03:00

24 lines
955 B
Diff

diff -up src/sage/libs/gap/util.pyx.orig src/sage/libs/gap/util.pyx
--- src/sage/libs/gap/util.pyx.orig 2015-04-03 15:10:03.911407815 -0300
+++ src/sage/libs/gap/util.pyx 2015-04-03 15:10:13.247408173 -0300
@@ -153,18 +153,9 @@ def gap_root():
sage: from sage.libs.gap.util import gap_root
sage: gap_root() # random output
- '/home/vbraun/opt/sage-5.3.rc0/local/gap/latest'
+ '/usr/lib/gap'
"""
- import os.path
- gapdir = os.path.join(SAGE_LOCAL, 'gap', 'latest')
- if os.path.exists(gapdir):
- return gapdir
- print 'The gap-4.5.5.spkg (or later) seems to be not installed!'
- gap_sh = open(os.path.join(SAGE_LOCAL, 'bin', 'gap')).read().splitlines()
- gapdir = filter(lambda dir:dir.strip().startswith('GAP_DIR'), gap_sh)[0]
- gapdir = gapdir.split('"')[1]
- gapdir = gapdir.replace('$SAGE_LOCAL', SAGE_LOCAL)
- return gapdir
+ return '/usr/lib/gap'
cdef initialize():