Changeset 3282 for SConstruct
- Timestamp:
- Jul 6, 2006, 12:31:47 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
SConstruct
r3259 r3282 2 2 import sys 3 3 4 env = Environment() 4 # Read in build options 5 opts = Options('build_options.py') 6 opts.Add('CFLAGS', 'Flags passed to the C Compiler') 7 8 env = Environment(options = opts, CCFLAGS=['${CFLAGS}']) 9 10 Help(opts.GenerateHelpText(env)) 5 11 6 12 # Find the path for Python.h and then share it to other SConscripts later on 7 13 # Where to find the Python.h 8 if sys.platform == 'win32': #Windows 14 if sys.platform == 'win32': 15 # Prefer MinGW over MSVC 16 env.Tools('mingw') 17 9 18 python_include = os.path.join(sys.exec_prefix, 'include') 10 19 # Windows installs need to be told the lib path and the python library name … … 12 21 python_libdir = os.path.join(sys.exec_prefix, 'libs') 13 22 try: 14 env['LIBPATH'] = env['LIBPATH'] +[python_libdir]23 env['LIBPATH'] += [python_libdir] 15 24 except KeyError: 16 25 env['LIBPATH'] = [python_libdir] 17 26 python_libname = 'python%d%d' % (sys.version_info[0], sys.version_info[1]) 18 27 try: 19 env['LIBS'] = env['LIBS'] +[python_libname]28 env['LIBS'] += [python_libname] 20 29 except KeyError: 21 30 env['LIBS'] = [python_libname] … … 35 44 36 45 try: 37 env['CPPPATH'] = env['CPPPATH'] +[python_include]46 env['CPPPATH'] += [python_include] 38 47 except KeyError: 39 48 env['CPPPATH'] = [python_include] … … 41 50 Export('env') 42 51 43 # Build the inundation modules44 52 SConscript(['inundation/SConscript'])
Note: See TracChangeset
for help on using the changeset viewer.