/[escript]/branches/ROBW_XPLATFORM/paso/src/SConscript
ViewVC logotype

Contents of /branches/ROBW_XPLATFORM/paso/src/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 623 - (show annotations)
Wed Mar 22 14:11:03 2006 UTC (15 years, 4 months ago) by robwdcock
File size: 1240 byte(s)
Beginning of a fully cross-platform (win32+intelc, linux+g++, altix+intelc)
scons build system
WORK IN PROGRESS NOT COMPLETE
+Incorporates ideas from trunks scons build system and the RW_WIN32 branch
+New Header layout as include/<modulename>, hence the changes to the headers
+Not all modules or features from trunk build system are fully implemented
-Removes need for intermediary SConstruct files - the top SConstruct is more complex but handle cross-platform better AND the SConscript are a LOT simpler
and only differ slightly. It should be simpler to maintain
-Options are now handled via either a: config file supplied on command line, a config file in the scons/hostname_options.py, or as individual command line arguments
-Need help with options: scons -h will give you a list of options and their current settings


1 Import('*')
2
3 local_env=env.Copy()
4
5 src_dir = local_env.Dir('.').srcnode().abspath
6
7 import os
8 filenames = os.listdir(src_dir)
9 sources = [x for x in filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]
10 headers = [x for x in filenames if os.path.splitext(x)[1] in ['.h']]
11 # Filter unused sources
12 sources.remove('SystemMatrixPattern_reduceBandwidth.c') # FIXME: Should this file be removed?
13
14 # Paso has additional source in the Solvers sub-directory. Append these to the list
15 solver_filenames = os.listdir(src_dir+'/Solvers');
16 sources += ['Solvers/'+x for x in solver_filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]
17 solver_headers = ['Solvers/'+x for x in solver_filenames if os.path.splitext(x)[1] in ['.h']]
18
19 if mkl_libs:
20 local_env.Append(CPPDEFINES=['MKL',])
21 if scsl_libs:
22 local_env.Append(CPPDEFINES=['SCSL',])
23 if umf_libs:
24 local_env.Append(CPPDEFINES=['UMFPACK',])
25 if papi_libs:
26 local_env.Append(CPPDEFINES=['PAPI',])
27
28 lib_name = 'paso'
29
30 lib = local_env.StaticLibrary(lib_name, sources)
31
32 include_path = Dir(lib_name, incinstall)
33 solvers_include_path = Dir('Solvers', include_path)
34
35 local_env.Install(include_path, headers )
36 local_env.Install(solvers_include_path, solver_headers )
37 local_env.Install(libinstall, lib)
38

  ViewVC Help
Powered by ViewVC 1.1.26