/[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 1133 by gross, Tue May 8 07:19:33 2007 UTC revision 2479 by gross, Thu Jun 18 06:50:37 2009 UTC
# Line 1  Line 1 
1    
2    ########################################################
3    #
4    # Copyright (c) 2003-2008 by University of Queensland
5    # Earth Systems Science Computational Center (ESSCC)
6    # http://www.uq.edu.au/esscc
7    #
8    # Primary Business: Queensland, Australia
9    # Licensed under the Open Software License version 3.0
10    # http://www.opensource.org/licenses/osl-3.0.php
11    #
12    ########################################################
13    
14    
15  import os  import os
16  Import('*')  Import('*')
17    
18  local_env=env.Copy()  local_env = clone_env(env_mpi)
19    
20    # And just for blocktimer cancer.....
21  # get the relevant file names:  local_env.Append(LIBS = ['esysUtils'])
 src_dir = local_env.Dir('.').srcnode().abspath  
 filenames = [ x for x in os.listdir(src_dir) if os.path.splitext(x)[1] in [".h", ".c", ".cpp"] ]  
   
 sources = [x for x in filenames if os.path.splitext(x)[1] in ['.cpp', '.c']]  
 headers = [x for x in filenames if os.path.splitext(x)[1] in ['.h']]  
   
 if mkl_libs:  
    local_env.Append(CPPDEFINES=['MKL',])  
    local_env.Append(LIBS = mkl_libs)  
 if scsl_libs:  
    local_env.Append(CPPDEFINES=['SCSL',])  
    local_env.Append(LIBS = scsl_libs)  
 if umf_libs:  
    local_env.Append(CPPDEFINES=['UMFPACK',])  
    local_env.Append(LIBS = umf_libs)  
 if papi_libs:  
    local_env.Append(CPPDEFINES=['PAPI',])  
    local_env.Append(LIBS = papi_libs)  
22    
23  lib_name = 'paso'  lib_name = 'paso'
24    
25  lib = local_env.StaticLibrary(lib_name, sources)  sources = """
26        BiCGStab.c
27        Coupler.c
28        Distribution.c
29        Functions.c
30        GMRES.c
31        GMRES2.c
32        MKL.c
33        NewtonGMRES.c
34        Options_getPackage.c
35        Options_getSolver.c
36        Options_setDefaults.c
37        PCG.c
38        Paso.c
39        PasoUtil.c
40        Paso_MPI.c
41        Pattern.c
42        Pattern_getSubpattern.c
43        Pattern_mis.c
44        Pattern_coupling.c
45        Pattern_reduceBandwidth.c
46        Pattern_unrollBlocks.c
47        SharedComponents.c
48        Solver.c
49        SolverFCT.c
50        SolverFCT_FluxControl.c
51        SolverFCT_reset.c
52        SolverFCT_solve.c
53        Solver_Function.c
54        Solver_GS.c
55        Solver_ILU.c
56        Solver_RILU.c
57        Solver_AMG.c
58        Solver_SchurComplement.c
59        Solver_applyBlockDiagonalMatrix.c
60        Solver_jacobi.c
61        Solver_preconditioner.c
62        SparseMatrix.c
63        SparseMatrix_MatrixVector.c
64        SparseMatrix_addAbsRow.c
65        SparseMatrix_addRow.c
66        SparseMatrix_getSubmatrix.c
67        SparseMatrix_nullifyRowsAndCols.c
68        SparseMatrix_saveHB.c
69        SparseMatrix_setValues.c
70        SystemMatrix.c
71        SystemMatrixPattern.c
72        SystemMatrixPattern_unrollBlocks.c
73        SystemMatrix_MatrixVector.c
74        SystemMatrix_borrowNormalization.c
75        SystemMatrix_getSystemMatrixTypeId.c
76        SystemMatrix_loadMM.c
77        SystemMatrix_nullifyRows.c
78        SystemMatrix_nullifyRowsAndCols.c
79        SystemMatrix_rowSum.c
80        SystemMatrix_saveHB.c
81        SystemMatrix_saveMM.c
82        SystemMatrix_setValues.c
83        TFQMR.c
84        MINRES.c
85        UMFPACK.c
86        mmio.c
87        performance.c
88        solve.c
89    """.split()
90    headers = """
91        Common.h
92        Coupler.h
93        Distribution.h
94        Functions.h
95        MKL.h
96        Options.h
97        Paso.h
98        PasoUtil.h
99        Paso_MPI.h
100        Pattern.h
101        Pattern_coupling.h
102        SharedComponents.h
103        Solver.h
104        SolverFCT.h
105        SparseMatrix.h
106        SystemMatrix.h
107        SystemMatrixPattern.h
108        UMFPACK.h
109        mmio.h
110        mpi_C.h
111        performance.h
112    """.split()
113    
114    if IS_WINDOWS_PLATFORM :
115      local_env.Append(CPPDEFINES = ['PASO_EXPORTS'])
116    
117    if local_env['share_paso'] :
118      lib = local_env.SharedLibrary(lib_name, sources)
119    else:
120      lib = local_env.StaticLibrary(lib_name, sources)
121    
122    env.Alias('target_paso_a', lib)
123    
124  include_path = Dir(lib_name, incinstall)  include_path = Dir('paso', local_env['incinstall'])
125  solvers_include_path = Dir('Solvers', include_path)  solvers_include_path = Dir('Solvers', include_path)
126    
127  local_env.Install(include_path, headers )  tmp1 = local_env.Install(include_path, headers )
128  local_env.Install(libinstall, lib)  env.Alias('target_install_paso_headers', [tmp1])
129    
130    tmp2 = local_env.Install(local_env['libinstall'], lib)
131    env.Alias('target_install_paso_a', [tmp2])
132    
 release_srcfiles = [ env.File(x) for x in filenames ]  + [env.File("SConscript"), ]  
 env.Zip(src_zipfile, release_srcfiles)  
 try:  
   env.Tar(src_tarfile, release_srcfiles)  
 except AttributeError:  
   pass  

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

  ViewVC Help
Powered by ViewVC 1.1.26