A boatload of changes and additions, all my Phoenix work for the past few days. Lots of lower level classes are wrapped, wxApp is working up through OnInit, plus there's a good start on some unit tests.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66272 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2010-11-27 08:53:17 +00:00
parent 2279df7926
commit 96717983ad
44 changed files with 3495 additions and 1073 deletions

View File

@@ -51,7 +51,7 @@ class Configuration(object):
SIPOPTS = ' '.join(['-k', # turn on keyword args support
'-o', # turn on auto-docstrings
'-e', # turn on exceptions support
#'-e', # turn on exceptions support
'-T', # turn off writing the timestamp to the generated files
#'-g', # always release and reaquire the GIL
#'-r', # turn on function call tracing
@@ -96,7 +96,7 @@ class Configuration(object):
NO_SCRIPTS = False
# Don't install the tools/script files
PKGDIR = 'wx'
PKGDIR = 'wxPhoenix'
# The name of the top-level package
# ---------------------------------------------------------------
@@ -145,8 +145,10 @@ class Configuration(object):
self.WXDIR = '..' # assumes wxPython is subdir
msg("WARNING: WXWIN not set in environment. Assuming '%s'" % self.WXDIR)
self.includes = ['sip/siplib'] # to get our version of sip.h
self.includes = ['sip/siplib', # to get our version of sip.h
'src', # for any hand-written headers
]
#---------------------------------------
# MSW specific settings
if os.name == 'nt' and self.COMPILER == 'msvc':
@@ -512,10 +514,12 @@ def msg(text):
if not runSilently:
print text
def opj(*args):
path = os.path.join(*args)
return os.path.normpath(path)
def posixjoin(a, *p):
"""Join two or more pathname components, inserting sep as needed"""
path = a
@@ -527,3 +531,20 @@ def posixjoin(a, *p):
else:
path = path + '/' + b
return path
def loadETG(name):
"""
Execute an ETG script so we can load a namespace with its contents (such
as a list of dependencies, etc.) for use by setup.py
"""
class _Namespace(object):
def __init__(self):
self.__dict__['__name__'] = 'namespace'
def nsdict(self):
return self.__dict__
ns = _Namespace()
execfile(name, ns.nsdict())
return ns

View File

@@ -17,9 +17,9 @@ import distutils.command.install
import distutils.command.install_data
import distutils.command.install_headers
import distutils.command.clean
from distutils.dep_util import newer
from distutils.dep_util import newer, newer_group
from config import Config, posixjoin
from config import Config, posixjoin, loadETG
@@ -361,7 +361,11 @@ class etgsip_build_ext(build_ext):
for etg in etg_sources:
sipfile = self.etg2sip(etg)
if newer(etg, sipfile):
deps = [etg]
ns = loadETG(etg)
if hasattr(ns, 'OTHERDEPS'):
deps += ns.OTHERDEPS
if newer_group(deps, sipfile):
cmd = [sys.executable, etg, '--sip']
#if cfg.verbose:
# cmd.append('--verbose')