ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/radiance/ray/src/util/SConscript
(Generate patch)

Comparing ray/src/util/SConscript (file contents):
Revision 1.20 by schorsch, Sat Mar 5 13:24:58 2016 UTC vs.
Revision 1.23 by schorsch, Mon Jan 8 13:38:37 2018 UTC

# Line 1 | Line 1
1 + from __future__ import division, print_function, unicode_literals
2 +
3   import os
4  
5   Import('env') # inherit from parent
# Line 15 | Line 17 | cmbsdf = env.Object(source='cmbsdf.c')
17  
18   # standard targets
19   PROGS = [
20 < ('findglare', Split('findglare.c glareval.c glaresrc.c setscan.c'),
21 <        ['rtpic','rtargs','rtio','rtproc','rtmath','rtpath','rtmem','rterror']),
22 < ('glarendx',  Split('glarendx.c'), ['rtpic','rtargs','rtio','rtmath']),
23 < ('vwright',   Split('vwright.c'),  ['rtpic','rtargs','rtio','rtmath']),
24 < ('vwrays',    Split('vwrays.c'),   ['rtpic','rtargs','rtio','rtmath']),
25 < ('rad',       Split('rad.c'),
26 <        ['rtpic','rtproc','rtpath','rtmath','rtargs','rtio','rtcont','rtmem','rterror']),
27 < ('rpiece',    Split('rpiece.c') + [env.version], # remote magic
28 <        ['rtpic','rtargs','rtio','rtproc','rtmath','rtpath','rtmem']),
29 < ('ranimate',  ['ranimate.c', '$RAD_NETCOMPAT'],
30 <        ['rtpic','rtargs','rtio','rtproc','rtcont','rtmem','rtpath','rtmath',
31 <        'rtnet','rterror','$RAD_SOCKETLIB']),
32 < ('dctimestep', Split('dctimestep.c')+[cmatrix, cmbsdf], ['rtall']),
33 < ('rttree_reduce', Split('rttree_reduce.c'), ['rtall']),
34 < ('rcollate', Split('rcollate.c'), ['rtall']),
33 < ('eplus_adduvf', Split('eplus_adduvf.c eplus_idf.c'), ['rtall']),
34 < ('rfluxmtx', Split('rfluxmtx.c'), ['rtall']),
35 < ('rmtxop', Split('rmtxop.c rmatrix.c')+[cmatrix, cmbsdf], ['rtall']),
36 < ('wrapBSDF', Split('wrapBSDF.c'), ['rtall']),
37 < ('evalglare', Split('evalglare.c pictool.c'), ['rtall', 'reetz']),
20 > ('findglare', Split('findglare.c glareval.c glaresrc.c setscan.c'), ['rtrad']),
21 > ('glarendx',  Split('glarendx.c'), ['rtrad']),
22 > ('vwright',   Split('vwright.c'),  ['rtrad']),
23 > ('vwrays',    Split('vwrays.c'),   ['rtrad']),
24 > ('rad',       Split('rad.c'),      ['rtrad']),
25 > ('rpiece',    Split('rpiece.c') + [env.version], ['rtrad']),
26 > ('ranimate',  ['ranimate.c', '$RAD_NETCOMPAT'], ['rtrad', '$RAD_SOCKETLIB']),
27 > ('dctimestep', Split('dctimestep.c')+[cmatrix, cmbsdf], ['rtrad']),
28 > ('rttree_reduce', Split('rttree_reduce.c'), ['rtrad']),
29 > ('rcollate', Split('rcollate.c'), ['rtrad']),
30 > ('eplus_adduvf', Split('eplus_adduvf.c eplus_idf.c'), ['rtrad']),
31 > ('rfluxmtx', Split('rfluxmtx.c'), ['rtrad']),
32 > ('rmtxop', Split('rmtxop.c rmatrix.c')+[cmatrix, cmbsdf], ['rtrad']),
33 > ('wrapBSDF', Split('wrapBSDF.c'), ['rtrad']),
34 > ('evalglare', Split('evalglare.c pictool.c'), ['rtrad', 'reetz']),
35   ]
36  
37   for p in PROGS:
# Line 45 | Line 42 | for p in PROGS:
42   rs = Split('ranimove.c ranimove1.c ranimove2.c')
43   ranimove = env.Program(target=radbin('ranimove'), source=rs,
44                  CPPPATH=env.get('CPPPATH', [])+ ['#src/rt'],
45 <                LIBS=['raycalls','rttrace','rtscene','rtpic','rtfunc','rtmath',
49 <                'rtnet','rtcont','rtmem','rtargs','rtio','rtproc','rtpath','rterror']
50 <                + mlib)
45 >                LIBS=['raycalls','rttrace','rtrad'] + mlib)
46   progs.append(ranimove)
47   rsensor = env.Program(target=radbin('rsensor'), source='rsensor.c',
48                  CPPPATH=env.get('CPPPATH', [])+ ['#src/rt'],
49 <                LIBS=['raycalls','rttrace','rtscene','rtpic','rtfunc','rtmath',
55 <                'rtcont','rtmem','rtargs','rtio','rtpath','rterror','rtproc',
56 <                'rtnet','rtlamps'] + mlib)
49 >                LIBS=['raycalls','rttrace','rtrad'] + mlib)
50   progs.append(rsensor)
51  
52   getinfo = env.Program(target=radbin('getinfo'), source='getinfo.c',
53 <                LIBS=['rtio'])
53 >                LIBS=['rtrad'])
54   progs.append(getinfo)
55  
56  
57   # X11 targets
58   if env.has_key('X11LIB'):
59 +        addobj = env.get('ADDOBJNOTIFY')
60          xincl = env.get('CPPPATH', []) + ['$X11INCLUDE']
61          xlibp = env.get('LIBPATH', []) + ['$X11LIB']
62          xglaresrc = env.Program(target=radbin('xglaresrc'),
63                          source=Split('xglaresrc.c') + [env.x11findwind], # XXX remote magic
64                          LIBPATH=xlibp, CPPPATH=xincl,
65 <                        LIBS=['rtpic','rtmath','rtargs','rtio','X11']+ mlib)
65 >                        LIBS=['rtrad', 'X11']+ mlib)
66          progs.append(xglaresrc)
67  
68          # OpenGL targets that also depend on X11
69          if env.has_key('OGL'):
70 <                glrad = env.Program(target=radbin('glrad'), source=Split('glrad.c'),
71 <                        CPPFLAGS=env.get('CPPFLAGS', []) + ['$RAD_STEREO'],
72 <                        LIBPATH=xlibp, CPPPATH=xincl,
73 <                        LIBS=['rgl','rtpic','rtscene','rtproc','rtpath','rtargs','rtio',
74 <                        'rtmath','rtcont','rtmem','rterror','rtdummy',
81 <                        'GL', 'GLU','X11'] + mlib,)
70 >                glrad = env.Program(target=radbin('glrad'),
71 >                                source=['glrad.c', addobj],
72 >                                CPPFLAGS=env.get('CPPFLAGS', []) + ['$RAD_STEREO'],
73 >                                LIBPATH=xlibp, CPPPATH=xincl,
74 >                                LIBS=['rgl','rtrad','GL', 'GLU','X11'] + mlib,)
75                  progs.append(glrad)
76  
77 < if os.name == 'posix': # XXX ignoring trad.wsh
77 > pyscripts = Split('''rlux''')
78 > if os.name == 'posix':
79          for s in Split('''objline glare dayfact
80 <                        debugcal rlux raddepend compamb vinfo fieldcomb'''):
80 >                        debugcal raddepend compamb vinfo fieldcomb'''):
81                  Default(env.InstallScript(radbin(s), s + '.csh'))
82          for s in Split('''objview objpict
83 <                        genambpos genklemsamp genskyvec genBSDF ltview ltpict'''):
83 >                        genambpos genklemsamp genskyvec genBSDF bsdfview ltview ltpict'''):
84                  Default(env.InstallScript(radbin(s), s + '.pl'))
85          for s in Split('''do_action.tcl do_file.tcl do_options.tcl do_results.tcl
86                  do_scene.tcl do_views.tcl do_zone.tcl file.hlp getfile.tcl gethelp.tcl
87                  help.hlp tclIndex trad.hlp trad.icon util.tcl'''):
88                  Default(env.InstallScript(tclscr(s), s))
89          Default(env.InstallTCLScript(radbin('trad'), 'trad.wsh'))
90 +        for s in pyscripts:
91 +                Default(env.InstallScript(radbin(s), s + '.py'))
92 + else:
93 +        for s in pyscripts:
94 +                Default(env.InstallScript(radbin(s + '.py'), s + '.py'))
95          
97 # Those don't really work yet
98 #else:
99 #       for s in Split('''objview glare rlux '''):
100 #               prog = env.Program(target=radbin(s), source=s+'.c')
101 #               progs.append(prog)
96  
97   Default('#src/util')
98   env.Install('$RAD_BINDIR', progs)
99  
100   # vim: set syntax=python:
101 + # vi: set ts=4 sw=4 :

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines