/[escript]/trunk/paso/src/SConscript
ViewVC logotype

Diff of /trunk/paso/src/SConscript

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 288 by jgs, Fri Dec 2 01:55:04 2005 UTC revision 1133 by gross, Tue May 8 07:19:33 2007 UTC
# Line 1  Line 1 
1  libinstall = None  import os
   
2  Import('*')  Import('*')
3    
4  import os  local_env=env.Copy()
5  import string  
6    
7  paso_path = str(esysroot) + '/paso/src'  # get the relevant file names:
8  scsl_path = str(esysroot) + '/paso/src/SCSL'  src_dir = local_env.Dir('.').srcnode().abspath
9  solvers_path = str(esysroot) + '/paso/src/Solvers'  filenames = [ x for x in os.listdir(src_dir) if os.path.splitext(x)[1] in [".h", ".c", ".cpp"] ]
10  mmio_path = str(esysroot) + '/tools/mmio/inc'  
11    sources = [x for x in filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]
12  cpp_path = [paso_path,  headers = [x for x in filenames if os.path.splitext(x)[1] in ['.h']]
13              scsl_path,  
14              solvers_path,  if mkl_libs:
15              mmio_path,     local_env.Append(CPPDEFINES=['MKL',])
16              python_path,     local_env.Append(LIBS = mkl_libs)
17              boost_path]  if scsl_libs:
18       local_env.Append(CPPDEFINES=['SCSL',])
19  lib = 'paso'     local_env.Append(LIBS = scsl_libs)
20  sources = ['Options_getPackage.c',  if umf_libs:
21             'Options_getSolver.c',     local_env.Append(CPPDEFINES=['UMFPACK',])
22             'Options_setDefaults.c',     local_env.Append(LIBS = umf_libs)
23             'Paso.c',  if papi_libs:
24             'solve.c',     local_env.Append(CPPDEFINES=['PAPI',])
25             'SystemMatrix_borrowNormalization.c',     local_env.Append(LIBS = papi_libs)
26             'SystemMatrix.c',  
27             'SystemMatrix_copy.c',  lib_name = 'paso'
28             'SystemMatrix_getSubmatrix.c',  
29             'SystemMatrix_getSystemMatrixTypeId.c',  lib = local_env.StaticLibrary(lib_name, sources)
30             'SystemMatrix_loadMM.c',  
31             'SystemMatrix_MatrixVector.c',  include_path = Dir(lib_name, incinstall)
32             'SystemMatrix_nullifyRowsAndCols.c',  solvers_include_path = Dir('Solvers', include_path)
33             'SystemMatrixPattern.c',  
34             'SystemMatrixPattern_getSubpattern.c',  local_env.Install(include_path, headers )
35             'SystemMatrixPattern_mis.c',  local_env.Install(libinstall, lib)
36             'SystemMatrixPattern_unrollBlocks.c',  
37             'SystemMatrix_saveHB.c',  release_srcfiles = [ env.File(x) for x in filenames ]  + [env.File("SConscript"), ]
38             'SystemMatrix_saveMM.c',  env.Zip(src_zipfile, release_srcfiles)
39             'SystemMatrix_setValues.c',  try:
40             'Util.c',    env.Tar(src_tarfile, release_srcfiles)
41             'SCSL/SCSL.c',  except AttributeError:
42             'SCSL/SCSL_direct.c',    pass
            'SCSL/SCSL_iterative.c',  
            'Solvers/BiCGStab.c',  
            'Solvers/GMRES.c',  
            'Solvers/PCG.c',  
            'Solvers/Solver_applyBlockDiagonalMatrix.c',  
            'Solvers/Solver.c',  
            'Solvers/Solver_ILU.c',  
            'Solvers/Solver_jacobi.c',  
            'Solvers/Solver_preconditioner.c',  
            'Solvers/Solver_SchurComplement.c']  
   
 paso_env = Environment(ENV = os.environ)  
   
 paso_env.Replace(CC = cc)  
 paso_env.Replace(CCFLAGS = cc_flags)  
 paso_env.Replace(ARFLAGS = ar_flags)  
 paso_env.Replace(CPPPATH = cpp_path)  
   
 paso_lib = paso_env.StaticLibrary(lib, sources)  
   
 paso_env.Install(libdir, paso_lib)  
 paso_env.Install(libdir2, paso_lib)  
 if libinstall != None:  
   paso_env.Install(libinstall, paso_lib)  

Legend:
Removed from v.288  
changed lines
  Added in v.1133

  ViewVC Help
Powered by ViewVC 1.1.26