/[escript]/trunk/scons/esys_options.py
ViewVC logotype

Diff of /trunk/scons/esys_options.py

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

revision 457 by jgs, Tue Jan 24 06:13:03 2006 UTC revision 805 by gross, Thu Aug 10 06:09:02 2006 UTC
# Line 1  Line 1 
1    
2    #          Copyright 2006 by ACcESS MNRF                  
3    #                                                          
4    #              http://www.access.edu.au                    
5    #       Primary Business: Queensland, Australia            
6    #  Licensed under the Open Software License version 3.0    
7    #     http://www.opensource.org/licenses/osl-3.0.php      
8    #                                                          
9    
10    
11    
12  # this code should be called by all esys13 scons builder and testing scripts  # this code should be called by all esys13 scons builder and testing scripts
13  # it sets default values for relevant variables and overloads them with the  # it sets default values for relevant variables and overloads them with the
14  # standard gcc settings by importing gcc_options. If there is  # standard gcc settings by importing gcc_options. If there is
# Line 6  Line 17 
17  # this is the general set up for the esys scons system:  # this is the general set up for the esys scons system:
18  libinstall = None  libinstall = None
19  pyinstall = None  pyinstall = None
20    incinstall = None
21  dodebug = 0  dodebug = 0
22    
23  # locations of libs etc used by mkl  # locations of libs etc used by mkl
# Line 23  umfpack_path = '' Line 35  umfpack_path = ''
35  umfpack_lib_path = ''  umfpack_lib_path = ''
36  umfpack_libs = []  umfpack_libs = []
37    
38    # locations of libs etc used by BLAS
39    blas_path = ''
40    blas_lib_path = ''
41    blas_libs = []
42    
43  # locations of include files for python  # locations of include files for python
44  python_path = Dir('/usr/include')  python_path = Dir('/usr/include')
45  python_lib_path =Dir('/usr/lib')  python_lib_path = Dir('/usr/lib')
46  python_lib = Library('python2.3')  python_lib = [ 'python2.3' ]
47    
48    # locations of PAPI
49    papi_path = ''
50    papi_lib_path = ''
51    papi_libs = []
52    
53  # locations of libraries for boost  # locations of libraries for boost
54  boost_path =Dir('/usr/include')  boost_path = '/usr/include'
55  boost_lib_path =Dir('/usr/lib')  boost_lib_path = '/usr/lib'
56  boost_lib = Library('boost_python')  boost_lib = 'boost_python'
57    
58    # locations of doc building executables
59    doxygen_path = ''
60    epydoc_path = ''
61    epydoc_pythonpath = ''
62    
63  # names of c and c++ compilers to use  # names of c and c++ compilers to use
64  cc = 'gcc'  cc = 'gcc'
# Line 70  usegcc = 0 Line 97  usegcc = 0
97  options = None  options = None
98  if ARGUMENTS.get('libinstall',0): libinstall = ARGUMENTS.get('libinstall',0)  if ARGUMENTS.get('libinstall',0): libinstall = ARGUMENTS.get('libinstall',0)
99  if ARGUMENTS.get('pyinstall',0): pyinstall = ARGUMENTS.get('pyinstall',0)  if ARGUMENTS.get('pyinstall',0): pyinstall = ARGUMENTS.get('pyinstall',0)
100    if ARGUMENTS.get('incinstall',0): pyinstall = ARGUMENTS.get('incinstall',0)
101  if ARGUMENTS.get('debug',0): dodebug = 1  if ARGUMENTS.get('debug',0): dodebug = 1
102  if ARGUMENTS.get('options',0): options = ARGUMENTS.get('options',0)  if ARGUMENTS.get('options',0): options = ARGUMENTS.get('options',0)
103  if ARGUMENTS.get('usegcc',0): usegcc = 1  if ARGUMENTS.get('usegcc',0): usegcc = 1
   
104  #  #
105  # try to import <hostname>_options  # try to import <hostname>_options
106  try:  try:
# Line 85  except ImportError: Line 112  except ImportError:
112  # try to import <hostname>_options  # try to import <hostname>_options
113  if usegcc==0:  if usegcc==0:
114     import socket     import socket
115     hostname = socket.gethostname()     from string import ascii_letters,digits
116       hostname=""
117       for s in socket.gethostname().split('.')[0]:
118            if s in ascii_letters+digits:
119               hostname+=s
120            else:
121               hostname+="_"
122     try:     try:
123        exec "from "+hostname+"_options import *"        exec "from "+hostname+"_options import *"
124     except ImportError:     except ImportError:
# Line 102  if dodebug==1: Line 135  if dodebug==1:
135       cxx_flags=cxx_flags_debug       cxx_flags=cxx_flags_debug
136       cc_flags=cc_flags_debug       cc_flags=cc_flags_debug
137    
138    #
139    # export configuration variables
140    #
141  Export(["esysroot"])  Export(["esysroot"])
142  Export(["libinstall"])  Export(["libinstall"])
143    Export(["incinstall"])
144  Export(["pyinstall"])  Export(["pyinstall"])

Legend:
Removed from v.457  
changed lines
  Added in v.805

  ViewVC Help
Powered by ViewVC 1.1.26