setup.py: no need to use cython build_ext
Seems to me that cythonize() is doing the same work, need some testing
This commit is contained in:
parent
c4bbbcf3dc
commit
03f2f286e2
4
setup.py
4
setup.py
|
@ -103,13 +103,11 @@ def pkg_config(name, require, min_vers=None):
|
||||||
# === cython or pre-generated c files ===
|
# === cython or pre-generated c files ===
|
||||||
if os.getenv("DISABLE_CYTHON"):
|
if os.getenv("DISABLE_CYTHON"):
|
||||||
module_suffix = ".c"
|
module_suffix = ".c"
|
||||||
from distutils.command.build_ext import build_ext
|
|
||||||
|
|
||||||
def cythonize(modules, *args, **kwargs):
|
def cythonize(modules, *args, **kwargs):
|
||||||
return modules
|
return modules
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
from Cython.Distutils import build_ext
|
|
||||||
from Cython.Build import cythonize
|
from Cython.Build import cythonize
|
||||||
import Cython.Compiler.Options
|
import Cython.Compiler.Options
|
||||||
except ImportError:
|
except ImportError:
|
||||||
|
@ -117,7 +115,6 @@ else:
|
||||||
raise SystemExit("Requires Cython >= %s (http://cython.org/)" % (
|
raise SystemExit("Requires Cython >= %s (http://cython.org/)" % (
|
||||||
CYTHON_MIN_VERSION))
|
CYTHON_MIN_VERSION))
|
||||||
module_suffix = ".c"
|
module_suffix = ".c"
|
||||||
from distutils.command.build_ext import build_ext
|
|
||||||
|
|
||||||
def cythonize(modules, *args, **kwargs):
|
def cythonize(modules, *args, **kwargs):
|
||||||
return modules
|
return modules
|
||||||
|
@ -444,7 +441,6 @@ setup(
|
||||||
'Topic :: Software Development :: Widget Sets',
|
'Topic :: Software Development :: Widget Sets',
|
||||||
],
|
],
|
||||||
cmdclass={
|
cmdclass={
|
||||||
'build_ext': build_ext,
|
|
||||||
'build_doc': BuildDoc,
|
'build_doc': BuildDoc,
|
||||||
'clean_generated_files': CleanGenerated
|
'clean_generated_files': CleanGenerated
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue