[sagemath] 02/02: Apply cython 0.25 patch from Arch Linux.

Tobias Hansen thansen at moszumanska.debian.org
Sun Nov 20 13:48:35 UTC 2016


This is an automated email from the git hooks/post-receive script.

thansen pushed a commit to branch master
in repository sagemath.

commit e4868c09b1db269515db2889a29e1730f97dfe81
Author: Tobias Hansen <thansen at broeselmaschine.fc.up.pt>
Date:   Sun Nov 20 13:41:55 2016 +0000

    Apply cython 0.25 patch from Arch Linux.
---
 debian/patches/debian-cython-sys-path.patch |  6 +++---
 debian/patches/debian-install-paths.patch   |  4 ++--
 debian/patches/series                       |  1 +
 debian/patches/version-cython-0.25.patch    | 33 +++++++++++++++++++++++++++++
 4 files changed, 39 insertions(+), 5 deletions(-)

diff --git a/debian/patches/debian-cython-sys-path.patch b/debian/patches/debian-cython-sys-path.patch
index 8775d46..937ecd9 100644
--- a/debian/patches/debian-cython-sys-path.patch
+++ b/debian/patches/debian-cython-sys-path.patch
@@ -5,14 +5,14 @@ Origin: https://git.archlinux.org/svntogit/community.git/tree/trunk?h=packages/s
 
 --- a/sage/src/setup.py
 +++ b/sage/src/setup.py
-@@ -613,6 +613,7 @@
+@@ -603,6 +603,7 @@
          build_dir=SAGE_CYTHONIZED,
          force=force,
          aliases=aliases,
 +        include_path=sys.path,
          compiler_directives={
-             'embedsignature': True,
-             'profile': profile,
+             'autotestdict': False,
+             'cdivision': True,
 --- a/sage/src/sage/misc/cython.py
 +++ b/sage/src/sage/misc/cython.py
 @@ -242,6 +242,7 @@
diff --git a/debian/patches/debian-install-paths.patch b/debian/patches/debian-install-paths.patch
index d684863..b392f89 100644
--- a/debian/patches/debian-install-paths.patch
+++ b/debian/patches/debian-install-paths.patch
@@ -90,7 +90,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
      m.include_dirs = m.include_dirs + libgap_include_dirs + include_dirs
  
  
-@@ -654,7 +654,7 @@
+@@ -647,7 +647,7 @@
  print('Cleaning up stale installed files....')
  t = time.time()
  from sage_setup.clean import clean_install_dir
@@ -125,7 +125,7 @@ This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
  
 --- a/sage/configure.ac
 +++ b/sage/configure.ac
-@@ -1004,8 +1004,7 @@
+@@ -1003,8 +1003,7 @@
                  AC_MSG_ERROR([[Cannot perform incremental update, run "make distclean && make"]])
              fi
          else
diff --git a/debian/patches/series b/debian/patches/series
index eefba8a..88512aa 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -21,6 +21,7 @@ version-python-2.7.11.patch
 version-ecm-7.patch
 version-singular-4.patch
 version-cddlib-094h.patch
+version-cython-0.25.patch
 version-glpk-4.60.patch
 version-pari-2.9-trac-21765.patch
 version-pari-2.9.patch
diff --git a/debian/patches/version-cython-0.25.patch b/debian/patches/version-cython-0.25.patch
new file mode 100644
index 0000000..0718d43
--- /dev/null
+++ b/debian/patches/version-cython-0.25.patch
@@ -0,0 +1,33 @@
+Description: Necessary changes to work with cython 0.25.
+Origin: https://git.archlinux.org/svntogit/community.git/tree/trunk?h=packages/sagemath
+
+--- a/sage/src/setup.py
++++ b/sage/src/setup.py
+@@ -562,16 +562,6 @@
+     import Cython.Compiler.Options
+     import Cython.Compiler.Main
+ 
+-    # Sage uses these directives (mostly for historical reasons).
+-    Cython.Compiler.Options.embed_pos_in_docstring = True
+-    Cython.Compiler.Options.directive_defaults['autotestdict'] = False
+-    Cython.Compiler.Options.directive_defaults['cdivision'] = True
+-    Cython.Compiler.Options.directive_defaults['fast_getattr'] = True
+-    # The globals() builtin in Cython was fixed to return to the current scope,
+-    # but Sage relies on the broken behavior of returning to the nearest
+-    # enclosing Python scope (e.g. to perform variable injection).
+-    Cython.Compiler.Options.old_style_globals = True
+-
+     debug = False
+     if os.environ.get('SAGE_DEBUG', None) != 'no':
+         print('Enabling Cython debugging support')
+@@ -608,7 +598,10 @@
+         force=force,
+         aliases=aliases,
+         compiler_directives={
++            'autotestdict': False,
++            'cdivision': True,
+             'embedsignature': True,
++            'fast_getattr': True,
+             'profile': profile,
+         })
+ 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/sagemath.git



More information about the debian-science-commits mailing list