/[escript]/trunk/escript/SConstruct
ViewVC logotype

Diff of /trunk/escript/SConstruct

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

revision 340 by jgs, Mon Dec 12 05:10:45 2005 UTC revision 425 by gross, Tue Jan 10 04:10:39 2006 UTC
# Line 1  Line 1 
 # Scons configuration file for escript  
   
 import os  
 import sys  
   
 #  
 # ensure correct versions of python and scons  
   
 EnsurePythonVersion(2,3)  
 EnsureSConsVersion(0,96)  
   
1  #  #
2  # set appropriate defaults for configuration variables  # set appropriate defaults for configuration variables
3    esysroot=str(Dir('./..').abspath)
4  esysroot = Dir('#..')  execfile(str(File(esysroot+"/scons/esys_options.py")))
 libinstall = None  
 pyinstall = None  
 dodebug = 0  
 usegcc = 0  
 options = None  
   
 #  
 # import configuration variables passed in from  
 # calling SConscript (if any)  
   
 Import('*')  
   
 #  
 # retreive command-line arguments if any  
   
 if ARGUMENTS.get('libinstall',0):  
   libinstall = ARGUMENTS.get('libinstall',0)  
 Export(["libinstall"])  
   
 if ARGUMENTS.get('pyinstall',0):  
   pyinstall = ARGUMENTS.get('pyinstall',0)  
   pyinstall = Dir(str(pyinstall) + '/escript')  
 Export(["pyinstall"])  
   
 if ARGUMENTS.get('debug',0):  
   dodebug = 1  
   
 if ARGUMENTS.get('usegcc',0):  
   usegcc = 1  
   
 if ARGUMENTS.get('options',0):  
   options = ARGUMENTS.get('options',0)  
   
 #  
 # determine platform  
   
 env = Environment(ENV = os.environ)  
 platform = env['PLATFORM']  
   
 #  
 # determine hostname  
   
 import socket  
 hostname = socket.gethostname()  
   
 #  
 # export esysroot  
   
 Export(["esysroot"])  
   
5  #  #
6  # set and export library directories  # set and export library directories
7    
# Line 79  Export(["pydir"]) Line 18  Export(["pydir"])
18  pydir2 = Dir(str(esysroot) + '/esys/escript')  pydir2 = Dir(str(esysroot) + '/esys/escript')
19  Export(["pydir2"])  Export(["pydir2"])
20    
 #  
 # load and export configuration settings  
   
 options_dir = str(esysroot) + '/scons'  
 sys.path.append(options_dir)  
   
 from default_options import *  
   
 if hostname=='ess':  
   from ess_options import *  
21    
22  if usegcc==1:  if pyinstall: pyinstall = Dir(str(pyinstall) + '/escript')
   from gcc_options import *  
   
 if options!=None:  
   exec "from " + options + " import *"  
   
 if dodebug==1:  
   cxx_flags=cxx_flags_debug  
23    
24  Export(["python_path"])  Export(["python_path"])
25  Export(["boost_path"])  Export(["boost_path"])
# Line 105  Export(["cxx"]) Line 27  Export(["cxx"])
27  Export(["cxx_flags"])  Export(["cxx_flags"])
28  Export(["boost_lib_path"])  Export(["boost_lib_path"])
29  Export(["boost_lib"])  Export(["boost_lib"])
30    Export(["python_lib_path"])
31    Export(["python_lib"])
32  Export(["sys_libs"])  Export(["sys_libs"])
33    Export(["pyinstall"])
34    Export(["libinstall"])
35    
36  #  #
37  # print out build configuration for this module  # print out build configuration for this module
38    
39  print "Build configuration for module: escript"  print "Build configuration for module: escript"
 print "         dodebug: ", dodebug  
 print "          usegcc: ", usegcc  
40  print "             cxx: ", cxx  print "             cxx: ", cxx
41  print "        platform: ", platform  print "       cxx_flags: ", cxx_flags
 print "        hostname: ", hostname  
 print "      libinstall: ", libinstall  
 print "       pyinstall: ", pyinstall  
42    
43  #  #
44  # call the SConscript to do the actual build  # call the SConscript to do the actual build

Legend:
Removed from v.340  
changed lines
  Added in v.425

  ViewVC Help
Powered by ViewVC 1.1.26