/[ascend]/trunk/pygtk/interface/SConscript
ViewVC logotype

Annotation of /trunk/pygtk/interface/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 393 - (hide annotations) (download)
Thu Mar 30 14:46:37 2006 UTC (14 years, 7 months ago) by johnpye
File size: 1203 byte(s)
Fixed SCons build to do output of config file 'config.py' require
by PyGTK GUI. Removed requirement for 'config.h' from the C++ file
and instead supplied required flags via compiler commandline.
1 johnpye 387 Import('env')
2    
3     srcs = Split("""
4    
5     library.cpp type.cpp module.cpp symchar.cpp
6     instance.cpp instanceinterfacedata.cpp
7     method.cpp name.cpp
8     reporter.cpp simulation.cpp set.cpp units.cpp dimensions.cpp extmethod.cpp
9     variable.cpp relation.cpp
10     solver.cpp curve.cpp plot.cpp
11     solverparameters.cpp solverparameter.cpp solverparameteriterator.cpp
12     solverstatus.cpp solverreporter.cpp
13     incidencematrix.cpp
14    
15     """)
16    
17     libs = Split("""
18     asccompiler ascpackages ascsolver ascutilities ascgeneral
19     """)
20    
21 johnpye 392 swig = CFile(target=['ascend_wrap.cc'],source=['ascend.i']
22     , SWIGFLAGS=['-python','-c++']
23     )
24     env.Depends('ascend.py',swig);
25    
26 johnpye 388 libpath = [
27     '../../base/generic/compiler'
28     ,'../../base/generic/packages'
29     ,'../../base/generic/solver'
30     ,'../../base/generic/utilities'
31     ,'../../base/generic/general'
32     ]
33 johnpye 387
34 johnpye 392 lib = env.SharedLibrary("ascend",srcs+swig
35     , LIBS = libs #+env['PYTHON_LIB']
36     , LIBPATH = libpath+env['PYTHON_LIBPATH']
37     , CPPPATH = ['../../base/generic']+env['PYTHON_CPPPATH']
38 johnpye 393 , CPPDEFINES = {
39     'ASCXX_USE_PYTHON':None
40     ,'DEFAULT_ASCENDLIBRARY':'\\"'+env['DEFAULT_ASCENDLIBRARY']+'\\"'
41     }
42 johnpye 392 , SHLIBPREFIX = '_'
43 johnpye 387 )
44 johnpye 392
45     env.Depends(lib,'ascend.py')
46 johnpye 393
47     print env['SUBST_DICT']
48    
49     env.SubstInFile(source='config.py.in')
50    

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22