mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-06 20:10:08 +01:00
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:
@@ -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
|
||||
|
||||
|
||||
@@ -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')
|
||||
|
||||
Reference in New Issue
Block a user