From: Robert Bradshaw Date: Thu, 2 Apr 2009 23:45:33 +0000 (-0700) Subject: Fix ticket #4, from package cimport module X-Git-Tag: 0.11.1.alpha~4 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=550bb60a2a9eb1589f045723045ddf44483ab346;p=cython.git Fix ticket #4, from package cimport module --- diff --git a/Cython/Compiler/Main.py b/Cython/Compiler/Main.py index 6fb86764..a2cb780c 100644 --- a/Cython/Compiler/Main.py +++ b/Cython/Compiler/Main.py @@ -254,7 +254,11 @@ class Context(object): if debug_find_module: print("......found ", pxd_pathname) if not pxd_pathname and need_pxd: - error(pos, "'%s.pxd' not found" % module_name) + package_pathname = self.search_include_directories(module_name, ".py", pos) + if package_pathname and package_pathname.endswith('__init__.py'): + pass + else: + error(pos, "'%s.pxd' not found" % module_name) if pxd_pathname: try: if debug_find_module: