diff options
author | Sam James <sam@gentoo.org> | 2021-03-06 03:22:42 +0000 |
---|---|---|
committer | Sam James <sam@gentoo.org> | 2021-03-06 03:22:59 +0000 |
commit | aab61be85302ce6e1ce7233a1fda3843d8ff1be8 (patch) | |
tree | 247e95580061eefaf4331614d4a82efe42cf6ca8 /dev-python/cython | |
parent | dev-libs/ntl: new upstream version 11.4.4. (diff) | |
download | gentoo-aab61be85302ce6e1ce7233a1fda3843d8ff1be8.tar.gz gentoo-aab61be85302ce6e1ce7233a1fda3843d8ff1be8.tar.bz2 gentoo-aab61be85302ce6e1ce7233a1fda3843d8ff1be8.zip |
dev-python/cython: rebase multiprocessing Darwin patch for 0.29.22
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-python/cython')
-rw-r--r-- | dev-python/cython/cython-0.29.22.ebuild | 2 | ||||
-rw-r--r-- | dev-python/cython/files/cython-0.29.22-spawn-multiprocessing.patch | 27 |
2 files changed, 28 insertions, 1 deletions
diff --git a/dev-python/cython/cython-0.29.22.ebuild b/dev-python/cython/cython-0.29.22.ebuild index 2fdee5a7f17b..d2fe1b9af4ef 100644 --- a/dev-python/cython/cython-0.29.22.ebuild +++ b/dev-python/cython/cython-0.29.22.ebuild @@ -31,7 +31,7 @@ BDEPEND="${RDEPEND} PATCHES=( "${FILESDIR}/${PN}-0.29.14-sphinx-update.patch" - "${FILESDIR}/${PN}-0.29.21-spawn-multiprocessing.patch" + "${FILESDIR}/${PN}-0.29.22-spawn-multiprocessing.patch" ) SITEFILE=50cython-gentoo.el diff --git a/dev-python/cython/files/cython-0.29.22-spawn-multiprocessing.patch b/dev-python/cython/files/cython-0.29.22-spawn-multiprocessing.patch new file mode 100644 index 000000000000..15b6f968e4bc --- /dev/null +++ b/dev-python/cython/files/cython-0.29.22-spawn-multiprocessing.patch @@ -0,0 +1,27 @@ +Needed to prevent a loop while calling cythonize on macOS - or any platform +defaulting to the 'spawn' method, as Python 3.8 does on Darwin. + +https://github.com/cython/cython/pull/3263 + +[Rebased on 0.29.22] + +From 15ae78bb74a856836dd64828326f4f0812d36520 Mon Sep 17 00:00:00 2001 +From: Marcel Bargull <marcel.bargull@udo.edu> +Date: Fri, 6 Dec 2019 18:21:19 +0100 +Subject: [PATCH] Disable parallel cythonization for "spawn" start method. + +--- +--- a/Cython/Build/Dependencies.py ++++ b/Cython/Build/Dependencies.py +@@ -1071,6 +1071,11 @@ def cythonize(module_list, exclude=None, nthreads=0, aliases=None, quiet=False, + + if N <= 1: + nthreads = 0 ++ if nthreads: ++ import multiprocessing ++ if multiprocessing.get_start_method() == 'spawn': ++ print('Disabling parallel cythonization for "spawn" process start method.') ++ nthreads = 0 + if nthreads: + # Requires multiprocessing (or Python >= 2.6) + try: |