# flags and values that affect this script
#----------------------------------------------------------------------
-VERSION = "2.3.2b2"
+VERSION = "2.3.2b7"
DESCRIPTION = "Cross platform GUI toolkit for Python"
AUTHOR = "Robin Dunn"
AUTHOR_EMAIL = "Robin Dunn <robin@alldunn.com>"
"""
-BUILD_GLCANVAS = 1 # If true, build the contrib/glcanvas extension module
+BUILD_GLCANVAS = 0 # If true, build the contrib/glcanvas extension module
BUILD_OGL = 1 # If true, build the contrib/ogl extension module
BUILD_STC = 1 # If true, build the contrib/stc extension module
BUILD_IEWIN = 0 # Internet Explorer wrapper (experimental)
# wxWindows must have been built with /MD, not /MDd
# (using FINAL=hybrid will do it.)
-WXDLLVER = '23_2' # Version part of DLL name
+WXDLLVER = '232' # Version part of DLL name
#----------------------------------------------------------------------
path = apply(os.path.join, args)
return os.path.normpath(path)
+def libFlag():
+ if FINAL:
+ return ''
+ elif HYBRID:
+ return 'h'
+ else:
+ return 'd'
+
+
#----------------------------------------------------------------------
# Some other globals
#----------------------------------------------------------------------
FINAL = 0
includes = ['src',
+ opj(WXDIR, 'lib', 'mswdll' + libFlag()),
opj(WXDIR, 'include'),
]
defines.append( ('__WXDEBUG__', None) )
libdirs = [opj(WXDIR, 'lib'), 'build\\ilib']
-
- if FINAL:
- wxdll = 'wx' + WXDLLVER
- elif HYBRID:
- wxdll = 'wx' + WXDLLVER + 'h'
- else:
- wxdll = 'wx' + WXDLLVER + 'd'
-
-
+ wxdll = 'wxmsw' + WXDLLVER + libFlag()
libs = [wxdll]
+
if bcpp_compiling:
libs = ['wx'+WXBCPPLIBVER]
+elif os.name == 'posix' and sys.platform == "darwin1":
+ # Flags and such for a Darwin (Max OS X) build of Python
+
+ WXDIR = '..' # assumes IN_CVS_TREE
+ WXPLAT = '__WXMAC__'
+ GENDIR = 'mac'
+
+ includes = ['src']
+ defines = [('SWIG_GLOBAL', None),
+ ('HAVE_CONFIG_H', None),
+ ('WXP_USE_THREAD', '1'),
+ ]
+ libdirs = []
+ libs = []
+
+ cflags = os.popen(WX_CONFIG + ' --cxxflags', 'r').read()[:-1]
+ cflags = string.split(cflags)
+
+ lflags = os.popen(WX_CONFIG + ' --libs', 'r').read()[:-1]
+ lflags = string.split(lflags)
+
+
+
elif os.name == 'posix':
# Set flags for Unix type platforms
libdirs = []
libs = []
- cflags = os.popen(WX_CONFIG + ' --cflags', 'r').read()[:-1] + ' ' + \
+ cflags = os.popen(WX_CONFIG + ' --cxxflags', 'r').read()[:-1] + ' ' + \
os.popen('gtk-config --cflags', 'r').read()[:-1]
cflags = string.split(cflags)
'-dnone',
#'-dascii',
#'-docstring', '-Sbefore',
- '-I./src', '-D'+WXPLAT]
+ '-I./src', '-D'+WXPLAT,
+ ]
swig_deps = ['src/my_typemaps.i']
gl_libs = []
if os.name == 'posix':
- if '-D__WXDEBUG__' in cflags:
- gl_libs = ['wx_gtkd_gl', 'GL', 'GLU']
- else:
- gl_libs = ['wx_gtk_gl', 'GL', 'GLU']
+ gl_config = os.popen(WX_CONFIG + ' --gl-libs', 'r').read()[:-1]
+ gl_lflags = string.split(gl_config) + lflags
+ gl_libs = libs
else:
other_sources = [opj(location, 'msw/myglcanvas.cpp')]
- gl_libs = ['opengl32', 'glu32']
-
+ gl_libs = libs + ['opengl32', 'glu32']
+ gl_lflags = lflags
ext = Extension('glcanvasc',
swig_sources + other_sources,
define_macros = defines,
library_dirs = libdirs,
- libraries = libs + gl_libs,
+ libraries = gl_libs,
extra_compile_args = cflags,
- extra_link_args = lflags,
+ extra_link_args = gl_lflags,
)
wxpExtensions.append(ext)
swig_files = ['stc_.i']
- swig_sources = run_swig(swig_files, location, '', PKGDIR,
+ swig_sources = run_swig(swig_files, location, GENDIR, PKGDIR,
USE_SWIG, swig_force,
swig_args + ['-I'+STC_H, '-I'+location],
[opj(STC_H, 'stc.h')])
'%s/scintilla/src/RESearch.cxx' % STCLOC,
'%s/scintilla/src/ScintillaBase.cxx' % STCLOC,
'%s/scintilla/src/Style.cxx' % STCLOC,
+ '%s/scintilla/src/StyleContext.cxx' % STCLOC,
'%s/scintilla/src/UniConversion.cxx' % STCLOC,
'%s/scintilla/src/ViewStyle.cxx' % STCLOC,
'%s/scintilla/src/WindowAccessor.cxx' % STCLOC,
'%s/scintilla/src/LexAda.cxx' % STCLOC,
'%s/scintilla/src/LexAVE.cxx' % STCLOC,
- '%s/scintilla/src/LexConf.cxx' % STCLOC,
'%s/scintilla/src/LexCPP.cxx' % STCLOC,
+ '%s/scintilla/src/LexConf.cxx' % STCLOC,
+ '%s/scintilla/src/LexCrontab.cxx' % STCLOC,
'%s/scintilla/src/LexEiffel.cxx' % STCLOC,
'%s/scintilla/src/LexHTML.cxx' % STCLOC,
'%s/scintilla/src/LexLisp.cxx' % STCLOC,