X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1128a89b82a3055e7d609f8f3a1e4bc9d2beea30..cfe5e918e6cbb28da4e4041b3fccfdaf538b247c:/wxPython/setup.py diff --git a/wxPython/setup.py b/wxPython/setup.py index 7ca50d7236..169a88cc4a 100755 --- a/wxPython/setup.py +++ b/wxPython/setup.py @@ -23,9 +23,22 @@ import sys # back and forth, and also more stuff in config.py will get converted # to functions, etc. +# This script imports it as just "config" because if wxPython doesn't +# exist yet, then it can't be imported from wx.build.config (since +# wx._core doesn't exist yet.) So instead we keep the main copy of +# config .py in the same place as setup.py, and then copy it to +# wx/build as needed below. + sys.setup_is_main = __name__ == "__main__" # an icky hack! -from wx.build.config import * +from config import * + + +#---------------------------------------------------------------------- +# Update the packaged config file. +#---------------------------------------------------------------------- +copy_file('config.py', 'wx/build', update=1, verbose=1) +CLEANUP.append('wx/build/config.py') #---------------------------------------------------------------------- # Update the version file @@ -433,7 +446,7 @@ if BUILD_STC: ## os.chdir(cwd) - swig_sources = run_swig(['stc.i'], location, '', PKGDIR, + swig_sources = run_swig(['stc.i'], location, GENDIR, PKGDIR, USE_SWIG, swig_force, swig_args + ['-I'+STC_H, '-I'+location], [opj(STC_H, 'stc.h')] + swig_deps) @@ -527,7 +540,7 @@ if BUILD_XRC: msg('Preparing XRC...') location = 'contrib/xrc' - swig_sources = run_swig(['xrc.i'], location, '', PKGDIR, + swig_sources = run_swig(['xrc.i'], location, GENDIR, PKGDIR, USE_SWIG, swig_force, swig_args, swig_deps + [ '%s/_xrc_rename.i' % location, '%s/_xrc_ex.py' % location,