[pypy-commit] cffi cffi-1.0: Initialize the __name__ and __file__ arguments when we're about to
arigo
noreply at buildbot.pypy.org
Mon May 18 13:38:51 CEST 2015
Author: Armin Rigo <arigo at tunes.org>
Branch: cffi-1.0
Changeset: r2044:a96e6eedc5cd
Date: 2015-05-18 13:39 +0200
http://bitbucket.org/cffi/cffi/changeset/a96e6eedc5cd/
Log: Initialize the __name__ and __file__ arguments when we're about to
execfile() the build script
diff --git a/cffi/setuptools_ext.py b/cffi/setuptools_ext.py
--- a/cffi/setuptools_ext.py
+++ b/cffi/setuptools_ext.py
@@ -42,7 +42,7 @@
rewritten + ':' + ffi_var_name,)
error("%r does not name an existing file%s" % (build_file_name, ext))
- mod_vars = {}
+ mod_vars = {'__name__': '__cffi__', '__file__': build_file_name}
execfile(build_file_name, mod_vars)
try:
More information about the pypy-commit
mailing list