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

Annotation of /trunk/modellib/SConstruct

Parent Directory Parent Directory | Revision Log Revision Log


Revision 325 - (hide annotations)
Wed Dec 7 02:08:17 2005 UTC (14 years, 9 months ago) by jgs
File size: 1200 byte(s)
now determine hostname via socket.gethostname() as HOSTNAME
environment variable is apparently not set on all platforms

1 jgs 268 # Scons configuration file for modellib
2    
3     import os
4     import sys
5    
6     #
7     # ensure correct versions of python and scons
8    
9     EnsurePythonVersion(2,3)
10     EnsureSConsVersion(0,96)
11    
12     #
13     # set appropriate defaults for configuration variables
14    
15     esysroot = Dir('#..')
16     pyinstall = None
17    
18     #
19     # import configuration variables passed in from
20     # calling SConscript (if any)
21    
22     Import('*')
23    
24     #
25     # retreive command-line arguments if any
26    
27     if ARGUMENTS.get('pyinstall',0):
28     pyinstall = ARGUMENTS.get('pyinstall',0)
29     Export(["pyinstall"])
30    
31     #
32     # determine platform
33    
34     env = Environment(ENV = os.environ)
35     platform = env['PLATFORM']
36    
37     #
38     # determine hostname
39    
40 jgs 325 import socket
41     hostname = socket.gethostname()
42 jgs 268
43     #
44     # export esysroot
45    
46     Export(["esysroot"])
47    
48     #
49     # set and export python directory
50    
51     pydir = Dir(str(esysroot) + '/modellib/lib/py_src')
52     Export(["pydir"])
53 jgs 288 pydir2 = Dir(str(esysroot) + '/esys/modellib')
54     Export(["pydir2"])
55 jgs 268
56     #
57     # print out build configuration for this module
58    
59     print "Build configuration for module: modellib"
60     print " platform: ", platform
61     print " hostname: ", hostname
62     print " pyinstall: ", pyinstall
63    
64     #
65     # call the SConscript to do the actual build
66    
67     SConscript(dirs=['py_src'], build_dir='obj/py_src', duplicate=0)

  ViewVC Help
Powered by ViewVC 1.1.26