gentoo/dev-python/cypari2/files/cypari2-2.2.0-regen-bindings-for-each-python.patch
François Bissey c96db0fc9b
dev-python/cypari2: add 2.2.0
Closes: https://github.com/gentoo/gentoo/pull/38155
Signed-off-by: François Bissey <frp.bissey@gmail.com>
Signed-off-by: Michael Orlitzky <mjo@gentoo.org>
2024-08-15 08:15:18 -04:00

26 lines
884 B
Diff

diff --git a/setup.py b/setup.py
index c1775b5..5051c6b 100755
--- a/setup.py
+++ b/setup.py
@@ -12,6 +12,10 @@ from autogen.paths import include_dirs, library_dirs
ext_kwds = dict(include_dirs=include_dirs(), library_dirs=library_dirs())
+# Generate auto-generated sources from pari.desc
+# This needs to be done before build/build_ext so the generated pxd is moved
+# to the build directory and installed with newer setuptools.
+rebuild()
if "READTHEDOCS" in os.environ:
# When building with readthedocs, disable optimizations to decrease
@@ -28,9 +32,6 @@ if "READTHEDOCS" in os.environ:
# Adapted from Cython's new_build_ext
class build_ext(_build_ext):
def finalize_options(self):
- # Generate auto-generated sources from pari.desc
- rebuild()
-
self.directives = {
"autotestdict.cdef": True,
"binding": True,