diff options
author | Armin Rigo <arigo@tunes.org> | 2015-07-09 12:35:18 +0100 |
---|---|---|
committer | Armin Rigo <arigo@tunes.org> | 2015-07-09 12:35:18 +0100 |
commit | 031ea0560ac1a5b492c52e3b11394438b90581d4 (patch) | |
tree | 7dc6f70cc15504be3635c799aa3efbc1fb33fe23 /pypy/goal | |
parent | Move "time" one level down the hierarchy of modules: nowadays we can't (diff) | |
download | pypy-031ea0560ac1a5b492c52e3b11394438b90581d4.tar.gz pypy-031ea0560ac1a5b492c52e3b11394438b90581d4.tar.bz2 pypy-031ea0560ac1a5b492c52e3b11394438b90581d4.zip |
Only do the final "Create cffi bindings for modules" step if the
_cffi_backend module is enabled. It is not, for example, with --sandbox
translations, which hang when used in this way.
Diffstat (limited to 'pypy/goal')
-rw-r--r-- | pypy/goal/targetpypystandalone.py | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/pypy/goal/targetpypystandalone.py b/pypy/goal/targetpypystandalone.py index 5a04ca3a5c..ee615a8d81 100644 --- a/pypy/goal/targetpypystandalone.py +++ b/pypy/goal/targetpypystandalone.py @@ -297,7 +297,12 @@ class PyPyTarget(object): options = make_dict(config) wrapstr = 'space.wrap(%r)' % (options) pypy.module.sys.Module.interpleveldefs['pypy_translation_info'] = wrapstr + if config.objspace.usemodules._cffi_backend: + self.hack_for_cffi_modules(driver) + return self.get_entry_point(config) + + def hack_for_cffi_modules(self, driver): # HACKHACKHACK # ugly hack to modify target goal from compile_c to build_cffi_imports # this should probably get cleaned up and merged with driver.create_exe @@ -336,8 +341,6 @@ class PyPyTarget(object): driver.default_goal = 'build_cffi_imports' # HACKHACKHACK end - return self.get_entry_point(config) - def jitpolicy(self, driver): from pypy.module.pypyjit.policy import PyPyJitPolicy from pypy.module.pypyjit.hooks import pypy_hooks |