/[ascend]/trunk/models/SConscript
ViewVC logotype

Contents of /trunk/models/SConscript

Parent Directory Parent Directory | Revision Log Revision Log


Revision 811 - (show annotations) (download)
Thu Aug 10 17:08:16 2006 UTC (13 years, 10 months ago) by johnpye
File size: 860 byte(s)
Added vim 'syntax=python' comments to many SConscript files.
Lots more work on the datareader extfn.
The testtmy.a4c file requires the file obtained here ('gzip -d' before use)
http://rredc.nrel.gov/solar/old_data/nsrdb/tmy2/unix/23161.tm2.Z
1 Import('env')
2
3 env.SConscript(['johnpye/SConscript'],['env'])
4
5 import os, os.path
6
7 modelfiles = []
8
9 excludedirs = ['.svn','CVS']
10 excludefiles = ['Makefile.in','SConscript','update-Makefile.pl']
11
12 modeldir = env.Dir(".").abspath
13
14 cwd = os.getcwd()
15 os.chdir(modeldir)
16 for root,dirs,files in os.walk("."):
17 for d in dirs:
18 if d in excludedirs:
19 dirs.remove(d)
20 for f in files:
21 if f in excludefiles:
22 continue
23 modelfiles.append( os.path.normpath(os.path.join(root,f)) )
24 os.chdir(cwd)
25
26 modelsroot = env['INSTALL_ROOT']+env['INSTALL_MODELS']
27
28 installeddirs = []
29
30 for f in modelfiles:
31 head,tail = os.path.split(f)
32 targetdir = os.path.join(modelsroot,head)
33 if not targetdir in installeddirs:
34 installeddirs.append(targetdir)
35 env.InstallShared(targetdir,f)
36
37 #print "MODEL INSTALLED DIRS =",installeddirs
38 Return('installeddirs')
39
40 # vim: set syntax=python:
41

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22