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

Diff of /trunk/tools/CppUnitTest/SConstruct

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

revision 325 by jgs, Wed Dec 7 02:08:17 2005 UTC revision 425 by gross, Tue Jan 10 04:10:39 2006 UTC
# Line 1  Line 1 
1  # Scons configuration file for CppUnitTest  # Scons configuration file for CppUnitTest
   
 import os  
 import sys  
   
 #  
 # ensure correct versions of python and scons  
   
 EnsurePythonVersion(2,3)  
 EnsureSConsVersion(0,96)  
   
 #  
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")))
 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('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"])  
   
 #  
 # set library directory  
5    
6  libdir = Dir(str(esysroot) + '/tools/CppUnitTest/lib')  libdir = Dir(str(esysroot) + '/tools/CppUnitTest/lib')
7  Export(["libdir"])  Export(["libdir"])
8    
 #  
 # 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 *  
   
 if usegcc==1:  
   from gcc_options import *  
   
 if options!=None:  
   exec "from " + options + " import *"  
   
 if dodebug==1:  
   cxx_flags=cxx_flags_debug  
   
9  Export(["cxx"])  Export(["cxx"])
10  Export(["cxx_flags"])  Export(["cxx_flags"])
11  Export(["ar_flags"])  Export(["ar_flags"])
# Line 86  Export(["ar_flags"]) Line 14  Export(["ar_flags"])
14  # print out build configuration for this module  # print out build configuration for this module
15    
16  print "Build configuration for module: CppUnitTest"  print "Build configuration for module: CppUnitTest"
 print "         dodebug: ", dodebug  
 print "          usegcc: ", usegcc  
17  print "             cxx: ", cxx  print "             cxx: ", cxx
18  print "        platform: ", platform  print "       cxx_flags: ", cxx_flags
 print "        hostname: ", hostname  
19    
20  #  #
21  # call the SConscript to do the actual build  # call the SConscript to do the actual build

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

  ViewVC Help
Powered by ViewVC 1.1.26