_dep_tree = DependencyTree(ctx)
return _dep_tree
-def create_extension_list(filepatterns, ctx):
+def create_extension_list(filepatterns, ctx=None):
+ if ctx is None:
+ from Cython.Compiler.Main import Context
+ ctx = Context(["."])
deps = create_dependency_tree(ctx)
if isinstance(filepatterns, str):
filepatterns = [filepatterns]
--- /dev/null
+PYTHON setup.py build_ext --inplace
+PYTHON -c "import a"
+
+######## setup.py ########
+
+from distutils.core import setup
+from distutils.extension import Extension
+from Cython.Distutils import build_ext
+
+setup(
+ cmdclass = {'build_ext': build_ext},
+ ext_modules = [Extension("a", ["a.pyx"])],
+)
+
+######## a.pyx ########
+