/[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 191 by jgs, Mon Nov 21 04:10:12 2005 UTC revision 214 by jgs, Thu Nov 24 05:15:26 2005 UTC
# Line 1  Line 1 
1  esysroot = None  # Scons configuration file for CppUnitTest
2    
3    import os
4    
5    #
6    # ensure correct versions of python and scons
7    
8    EnsurePythonVersion(2,3)
9    EnsureSConsVersion(0,96)
10    
11    #
12    # set appropriate defaults for configuration variables
13    
14    esysroot = Dir('#../..')
15    dodebug = 0
16    usegcc = 0
17    
18    #
19    # import configuration variables passed in from
20    # calling SConscript (if any)
21    
22  Import('*')  Import('*')
23    
24  if esysroot == None:  #
25    esysroot = Dir('#../..')  # retreive command-line arguments if any
26    
27    if ARGUMENTS.get('debug',0):
28      dodebug = 1
29    
30    if ARGUMENTS.get('usegcc',0):
31      usegcc = 1
32    
33    #
34    # determine platform
35    
36    env = Environment(ENV = os.environ)
37    platform = env['PLATFORM']
38    
39    #
40    # determine hostname
41    
42    hostname = os.environ['HOSTNAME']
43    
44    #
45    # export esysroot
46    
47  Export(["esysroot"])  Export(["esysroot"])
48    
49    #
50    # set library directory
51    
52  libdir = Dir(str(esysroot) + '/tools/CppUnitTest/lib')  libdir = Dir(str(esysroot) + '/tools/CppUnitTest/lib')
53  Export(["libdir"])  Export(["libdir"])
54    
55    #
56    # load and export configuration settings
57    
58  cxx_flags = '-O0 -openmp -openmp_report0 -tpp2 -ansi -ansi_alias -no-gcc -fpic -w1'  cxx_flags = '-O0 -openmp -openmp_report0 -tpp2 -ansi -ansi_alias -no-gcc -fpic -w1'
59    
60  Export(["cxx_flags"])  Export(["cxx_flags"])
61    
62    #
63    # print out build configuration for this module
64    
65    print "############################################"
66    print "Build configuration for module: CppUnitTest"
67    print "         dodebug: ", dodebug
68    print "          usegcc: ", usegcc
69    print "        platform: ", platform
70    print "        hostname: ", hostname
71    print "############################################"
72    
73    #
74    # call the SConscript to do the actual build
75    
76  SConscript('src/SConscript', src_dir='src', build_dir='obj', duplicate=0)  SConscript('src/SConscript', src_dir='src', build_dir='obj', duplicate=0)

Legend:
Removed from v.191  
changed lines
  Added in v.214

  ViewVC Help
Powered by ViewVC 1.1.26