diff options
author | Thomas Heller <theller@ctypes.org> | 2006-04-07 19:27:56 (GMT) |
---|---|---|
committer | Thomas Heller <theller@ctypes.org> | 2006-04-07 19:27:56 (GMT) |
commit | 795246cf9937f088f8d98253f38da4a093c08300 (patch) | |
tree | 34008d9bc687286cf1f4249476edb5fd016f63ed /setup.py | |
parent | eba43c157b1ed57bf95144f704d56c3296a6f637 (diff) | |
download | cpython-795246cf9937f088f8d98253f38da4a093c08300.zip cpython-795246cf9937f088f8d98253f38da4a093c08300.tar.gz cpython-795246cf9937f088f8d98253f38da4a093c08300.tar.bz2 |
Don't try to build ctypes when configuration of libffi fails.
Diffstat (limited to 'setup.py')
-rw-r--r-- | setup.py | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -181,7 +181,8 @@ class PyBuildExt(build_ext): def build_extension(self, ext): if ext.name == '_ctypes': - self.configure_ctypes(ext) + if not self.configure_ctypes(ext): + return try: build_ext.build_extension(self, ext) @@ -1287,7 +1288,7 @@ class PyBuildExt(build_ext): res = os.system(cmd) if res or not os.path.exists(ffi_configfile): print "Failed to configure _ctypes module" - return + return False fficonfig = {} execfile(ffi_configfile, globals(), fficonfig) @@ -1303,6 +1304,7 @@ class PyBuildExt(build_ext): ext.sources.extend(fficonfig['ffi_sources']) ext.include_dirs.extend(include_dirs) ext.extra_compile_args.extend(extra_compile_args) + return True def detect_ctypes(self): include_dirs = [] |