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

Comparing ray/src/rt/Rmakefile (file contents):
Revision 1.24 by greg, Thu Mar 29 13:32:31 1990 UTC vs.
Revision 2.20 by greg, Fri Dec 8 18:22:25 1995 UTC

# Line 1 | Line 1
1 + #
2   # SCCSid "$SunId$ LBL"
3 <
3 > # Compiles for ray tracing programs.
4   #
4 #  Compiles for ray tracing programs.
5 #
5  
6   OPT = -O
7 < MACH = -DSTRUCTASSIGN -DBSD -DIEEE -f68881 /usr/lib/f68881.il
8 < CFLAGS = $(MACH) $(OPT)
7 > MACH = -DBSD
8 > CFLAGS = $(MACH) $(OPT) -I../common -L../lib
9 > SPECIAL = aed
10 > CC = cc
11 > MLIB = -lm
12 > LINT = lint
13 > LINTFLAGS = -DBSD -DVARIABLE -DFUNCTION \
14 > -DINCHAN -DRCONST -DREDEFW
15  
16   #
17   # The following are user-definable:
18   #
19   DESTDIR = .
20 < INSTDIR = /usr/local/ray
20 > INSTDIR = /usr/local/bin
21   INSTALL = cp
22  
23   #
24   # The following paths must exist and be relative to root:
25   #
26 < DEVDIR = $(INSTDIR)
26 > DEVDIR = $(INSTDIR)/dev
27   LIBDIR = /usr/local/lib/ray
28  
29   #
30   # Library routines:
31   #
32 < LIBS = -lm
28 < COMPAT = malloc.o
32 > LIBS = -lrt $(MLIB)
33  
34   #
35   # Device drivers for rview (see also devtable.c):
36   #
37 < DOBJS = devtable.o devcomm.o aed.o tty.o editline.o x10.o xtwind.o \
37 > DOBJS = devtable.o devcomm.o editline.o x11.o x11twind.o \
38          colortab.o
39 < DLIBS = -lX
40 < DRIVERS = $(DEVDIR)/sundev $(DEVDIR)/sun.com $(DEVDIR)/x11dev
39 > DSRC = devtable.c devcomm.c editline.c x11.c x11twind.c \
40 >        colortab.c
41 > DLIBS = -lX11
42  
43   #
44   # Standard object files:
45   #
46  
47 < RTOBJS = rtmain.o rtrace.o $(ROBJS)
47 > RTOBJS = rtmain.o rtrace.o duphead.o persist.o preload.o $(ROBJS) Version.o
48 > RTSRC = rmain.c rtrace.c $(RSRC) Version.c
49  
50 < RPOBJS = rpmain.o rpict.o image.o $(ROBJS)
50 > RPOBJS = rpmain.o rpict.o duphead.o persist.o preload.o $(ROBJS) Version.o
51 > RPSRC = rmain.c rpict.c $(RSRC) Version.c
52  
53 < RVOBJS = rvmain.o rview.o rv2.o rv3.o image.o $(DOBJS) $(ROBJS)
53 > RVOBJS = rvmain.o rview.o rv2.o rv3.o freeobjmem.o $(DOBJS) $(ROBJS) Version.o
54 > RVSRC = rmain.c rview.c rv2.c rv3.c freeobjmem.c $(DSRC) $(RSRC) Version.c
55  
56 < ROBJS = $(OCTOBJS) $(RAYOBJS) $(SURFOBJS) $(MATOBJS) \
57 <        $(MODOBJS) $(SUPPOBJS) $(MISCOBJS) $(COMPAT)
56 > ROBJS = $(RAYOBJS) $(SURFOBJS) $(MATOBJS) \
57 >        $(MODOBJS) $(SUPPOBJS)
58 > RSRC = $(RAYSRC) $(SURFSRC) $(MATSRC) \
59 >        $(MODSRC) $(SUPPSRC)
60  
61 < OCTOBJS = octree.o readobj.o readoct.o objset.o otypes.o
61 > RAYOBJS = initotypes.o raytrace.o ambient.o ambcomp.o ambio.o
62 > RAYSRC = initotypes.c raytrace.c ambient.c ambcomp.c ambio.c
63  
64 < RAYOBJS = raytrace.o ambient.o
64 > SURFOBJS = source.o sphere.o srcsupp.o srcsamp.o virtuals.o o_face.o \
65 >        o_cone.o o_instance.o
66 > SURFSRC = sphere.c source.c srcsupp.c virtuals.c o_face.c \
67 >                srcsamp.c o_cone.c o_instance.c
68  
69 < SURFOBJS = face.o sphere.o source.o o_face.o cone.o \
70 <                o_cone.o o_instance.o instance.o
69 > MATOBJS = aniso.o normal.o dielectric.o m_clip.o glass.o m_brdf.o \
70 >        m_mirror.o m_direct.o m_mist.o fprism.o
71 > MATSRC = aniso.c normal.c dielectric.c m_clip.c glass.c m_brdf.c \
72 >        m_mirror.c m_direct.c m_mist.c fprism.c
73  
58 MATOBJS = normal.o dielectric.o m_clip.o glass.o
59
74   MODOBJS = p_func.o t_func.o p_data.o t_data.o text.o mx_func.o mx_data.o
75 + MODSRC = p_func.c t_func.c p_data.c t_data.c text.c mx_func.c mx_data.c
76  
77 < SUPPOBJS = zeroes.o calexpr.o caldefn.o calfunc.o func.o noise3.o data.o
77 > SUPPOBJS = zeroes.o calexpr.o caldefn.o func.o noise3.o malloc.o data.o \
78 >        readfargs.o
79 > SUPPSRC = zeroes.c calexpr.c caldefn.c func.c noise3.c data.c malloc.c \
80 >        readfargs.c
81  
82 < MISCOBJS = misc.o color.o header.o mat4.o xf.o fvect.o savestr.o \
65 <                fgetline.o ealloc.o
82 > HEADERS = ambient.h ray.h data.h otspecial.h source.h
83  
84   #
85   # What this makefile produces:
# Line 70 | Line 87 | MISCOBJS = misc.o color.o header.o mat4.o xf.o fvect.o
87  
88   PROGS = $(DESTDIR)/rtrace $(DESTDIR)/rpict $(DESTDIR)/rview $(DESTDIR)/lookamb
89  
90 < all:    $(PROGS) $(DRIVERS)
90 > all:    $(PROGS) $(SPECIAL)
91  
92 < install:        all
92 > install:        $(PROGS) $(SPECIAL) rayinit.cal
93          $(INSTALL) $(PROGS) $(INSTDIR)
94 +        rm -f $(LIBDIR)/rayinit.cal
95 +        cp rayinit.cal $(LIBDIR)
96  
97 + sun:    $(DEVDIR)/sun $(DEVDIR)/sun.com
98 +
99 + x10:    $(DEVDIR)/x10
100 +
101 + aed:    $(DEVDIR)/aed
102 +
103 + sgi:    $(DEVDIR)/news
104 +
105 + tiff:  
106 +
107   clean:
108 <        rm -f *.o core
108 >        set nonomatch; rm -f $(PROGS) *.o core
109  
110 + lint:   $(RVSRC)
111 +        $(LINT) $(LINTFLAGS) -DRVIEW $(RVSRC) $(LIBS)
112 +
113   #
114   # Links:
115   #
116  
117   $(DESTDIR)/rtrace:      $(RTOBJS)
118 <        cc $(CFLAGS) -o $(DESTDIR)/rtrace $(RTOBJS) $(LIBS)
118 >        $(CC) $(CFLAGS) -o $(DESTDIR)/rtrace $(RTOBJS) $(LIBS)
119  
120   $(DESTDIR)/rpict:       $(RPOBJS)
121 <        cc $(CFLAGS) -o $(DESTDIR)/rpict $(RPOBJS) $(LIBS)
121 >        $(CC) $(CFLAGS) -o $(DESTDIR)/rpict $(RPOBJS) $(LIBS)
122  
123   $(DESTDIR)/rview:       $(RVOBJS)
124 <        cc $(CFLAGS) -o $(DESTDIR)/rview $(RVOBJS) $(DLIBS) $(LIBS)
124 >        $(CC) $(CFLAGS) -o $(DESTDIR)/rview $(RVOBJS) $(DLIBS) $(LIBS)
125  
126 < $(DESTDIR)/lookamb:     lookamb.o
127 <        cc $(CFLAGS) -o $(DESTDIR)/lookamb lookamb.o
126 > $(DESTDIR)/lookamb:     lookamb.o ambio.o
127 >        $(CC) $(CFLAGS) -o $(DESTDIR)/lookamb lookamb.o ambio.o -lrt
128  
129 < $(DEVDIR)/sundev:       sundev.o devmain.o colortab.o editline.o
130 <        cc $(CFLAGS) -o $(DEVDIR)/sundev devmain.o sundev.o colortab.o \
129 > $(DEVDIR)/sun:  sundev.o devmain.o colortab.o editline.o
130 >        $(CC) $(CFLAGS) -s -o $(DEVDIR)/sun devmain.o sundev.o colortab.o \
131   editline.o -lsuntool -lsunwindow -lpixrect $(LIBS)
132  
133   $(DEVDIR)/sun.com:      suncom.o editline.o
134 <        cc $(CFLAGS) -o $(DEVDIR)/sun.com suncom.o editline.o
134 >        $(CC) $(CFLAGS) -s -o $(DEVDIR)/sun.com suncom.o editline.o
135  
136 < $(DEVDIR)/x11dev:       x11.o x11twind.o colortab.o devmain.o editline.o
137 <        cc $(CFLAGS) -o $(DEVDIR)/x11dev x11.o x11twind.o devmain.o \
138 < colortab.o editline.o -lX11 $(LIBS)
136 > $(DEVDIR)/x10:  x10.o xtwind.o colortab.o devmain.o editline.o
137 >        $(CC) $(CFLAGS) -s -o $(DEVDIR)/x10 x10.o xtwind.o devmain.o \
138 > colortab.o editline.o -lX $(LIBS)
139  
140 + $(DEVDIR)/aed:  aed.o colortab.o tty.o devmain.o editline.o
141 +        $(CC) $(CFLAGS) -s -o $(DEVDIR)/aed aed.o colortab.o \
142 + devmain.o tty.o editline.o $(LIBS)
143 +
144 + $(DEVDIR)/news: nwsdev.o devmain.o editline.o
145 +        $(CC) $(CFLAGS) -s -o $(DEVDIR)/news nwsdev.o devmain.o editline.o \
146 + -lcps $(LIBS)
147 +
148   #
149   # Special compiles:
150   #
151  
152   rtmain.o:       rmain.c
153 <        cc $(CFLAGS) -DRTRACE -DNICE=4 -DDEFPATH=\":$(LIBDIR)\" -c rmain.c
153 >        $(CC) $(CFLAGS) -DRTRACE -DNICE=4 -c rmain.c
154          mv rmain.o rtmain.o
155  
156   rpmain.o:       rmain.c
157 <        cc $(CFLAGS) -DRPICT -DNICE=6 -DDEFPATH=\":$(LIBDIR)\" -c rmain.c
157 >        $(CC) $(CFLAGS) -DRPICT -DNICE=6 -c rmain.c
158          mv rmain.o rpmain.o
159  
160   rvmain.o:       rmain.c
161 <        cc $(CFLAGS) -DRVIEW -DDEFPATH=\":$(LIBDIR)\" -c rmain.c
161 >        $(CC) $(CFLAGS) -DRVIEW -c rmain.c
162          mv rmain.o rvmain.o
163  
164 + readfargs.o:    readfargs.c ../common/object.h
165 +        $(CC) $(CFLAGS) -DMEMHOG -c readfargs.c
166 +
167 + malloc.o:       malloc.c
168 +        $(CC) $(CFLAGS) -DMCOMP -c malloc.c
169 +
170   #
171   # Uncomment the following to model dispersion:
172   #
173 < #dielectric.o:  dielectric.c source.h
174 < #       cc $(CFLAGS) -DDISPERSE -c dielectric.c
175 < #
130 < #color.o:       color.c color.h
131 < #       cc $(CFLAGS) -DSPEC_RGB -c color.c
132 < #
173 > dielectric.o:   dielectric.c source.h
174 >        $(CC) $(CFLAGS) -DDISPERSE -c dielectric.c
175 >
176   # end of dispersion compiles.
177  
178 + devcomm.o:      devcomm.c
179 +        $(CC) $(CFLAGS) -DDEVPATH=\"$(DEVDIR)\" -c devcomm.c
180 +
181   sundev.o:       sundev.c
182 <        cc $(CFLAGS) -Dsun_init=dinit -c sundev.c
182 >        $(CC) $(CFLAGS) -DTTYPROG=\"$(DEVDIR)/sun.com\" -Dsun_init=dinit -c sundev.c
183  
184 < x11.o:  x11.c
185 <        cc $(CFLAGS) -Dx11_init=dinit -c x11.c
184 > x10.o:  x10.c
185 >        $(CC) $(CFLAGS) -Dx_init=dinit -c x10.c
186  
187 < ambient.o:      ambient.c
188 <        cc $(CFLAGS) -DAMBFLUSH=16 -c ambient.c
187 > aed.o:  aed.c
188 >        $(CC) $(CFLAGS) -Daed_init=dinit -c aed.c
189  
190 < calexpr.o:      calexpr.c calcomp.h
191 <        cc $(CFLAGS) -DVARIABLE -DFUNCTION -DINCHAN -DRCONST -c calexpr.c
190 > calexpr.o:      calexpr.c ../common/calcomp.h
191 >        $(CC) $(CFLAGS) -DVARIABLE -DFUNCTION -DINCHAN -DRCONST -c calexpr.c
192  
193 < caldefn.o:      caldefn.c calcomp.h
194 <        cc $(CFLAGS) -DFUNCTION -c caldefn.c
193 > caldefn.o:      caldefn.c ../common/calcomp.h
194 >        $(CC) $(CFLAGS) -DFUNCTION -DREDEFW -c caldefn.c
195  
196 < calfunc.o:      calfunc.c calcomp.h
197 <        cc $(CFLAGS) -DVARIABLE -DBIGLIB -c calfunc.c
196 > nwsdev.o:       nwsdev.c nwsdev.h newsconstants.h
197 >        $(CC) $(CFLAGS) -Dnws_init=dinit -c nwsdev.c
198  
199 < xf.o:   xf.c
200 <        cc $(CFLAGS) -DINVXF -c xf.c
199 > nwsdev.h:       nwsdev.cps newsconstants.h
200 >        cps nwsdev.cps
201  
202   #
203 < # Include dependencies:
203 > # Version module:
204   #
205  
206 < caldefn.o calexpr.o calfunc.o:  calcomp.h
206 > Version.c:      VERSION $(RSRC) $(HEADERS)
207 >        ( cat VERSION ; date ; whoami ; hostname ) > Version.c
208 >        ed - Version.c < verscript.ed
209  
210 < aed.o color.o colortab.o data.o devcomm.o \
211 < devmain.o lookamb.o rview.o sundev.o x10.o x11.o:       color.h
210 > #
211 > # Include dependencies:
212 > #
213  
214 < cone.o o_cone.o source.o:       cone.h
214 > aed.o ambio.o colortab.o data.o devcomm.o \
215 > devmain.o lookamb.o rview.o sundev.o x10.o x11.o:       ../common/color.h
216  
217 < data.o mx_data.o p_data.o t_data.o:     data.h
217 > o_cone.o srcsupp.o:     ../common/cone.h
218  
219 + data.o m_brdf.o mx_data.o p_data.o t_data.o:    data.h
220 +
221   aed.o devcomm.o devmain.o devtable.o \
222 < editline.o sundev.o tty.o x10.o x11.o:  driver.h
222 > editline.o nwsdev.o sundev.o tty.o x10.o x11.o: driver.h
223  
224 < face.o o_face.o source.o:       face.h
224 > o_face.o srcsupp.o:     ../common/face.h
225  
226 < fvect.o:        fvect.h
226 > ambient.o raytrace.o rpmain.o rtmain.o \
227 > rtrace.o rvmain.o rv2.o rv3.o source.o: ../common/octree.h
228  
229 < cone.o face.o objset.o otypes.o readobj.o readoct.o:    object.h
229 > o_instance.o:   ../common/instance.h ../common/octree.h
230  
231 < ambient.o objset.o octree.o raytrace.o \
232 < readoct.o rpmain.o rtmain.o rvmain.o rv2.o rv3.o source.o:      octree.h
231 > ambient.c aniso.c dielectric.c freeobjmem.c func.c initotypes.c \
232 > m_brdf.c m_direct.c m_mirror.c normal.c o_cone.c preload.c \
233 > raytrace.c rtrace.c rv2.c source.c sphere.c srcsupp.c text.c \
234 > virtuals.c:     ../common/otypes.h
235  
236 < o_instance.o instance.o:        instance.h octree.h
236 > ambient.o ambcomp.o aniso.o normal.o rpict.o \
237 > source.o rv3.o srcsamp.o virtuals.o:    ../common/random.h
238  
239 < ambient.o cone.o dielectric.o func.o normal.o o_cone.o otypes.o \
240 < text.o raytrace.o readobj.o readoct.o rtrace.o \
185 < rv2.o source.o sphere.o:        otypes.h
186 <
187 < ambient.o rpict.o rv3.o source.o:       random.h
188 <
189 < ambient.o dielectric.o func.o glass.o m_clip.o \
190 < mx_data.o mx_func.o normal.o o_cone.o o_face.o o_instance.o \
239 > ambient.o ambcomp.o aniso.o dielectric.o func.o glass.o m_clip.o m_mirror.o \
240 > m_brdf.o mx_data.o mx_func.o normal.o o_cone.o o_face.o o_instance.o \
241   p_data.o p_func.o text.o raytrace.o rpmain.o rtmain.o rvmain.o rpict.o \
242 < rtrace.o rv2.o rv3.o source.o \
243 < sphere.o t_data.o t_func.o:     ray.h standard.h fvect.h object.h color.h
242 > rtrace.o rview.o rv2.o rv3.o source.o srcsamp.o srcsupp.o virtuals.o \
243 > sphere.o m_mist.o t_data.o t_func.o persist.o:  ray.h ../common/standard.h \
244 > ../common/mat4.h ../common/fvect.h ../common/object.h ../common/color.h
245  
246 < rv2.o rv3.o rview.o:    rpaint.h driver.h view.h
246 > rv2.o rv3.o rview.o:    rpaint.h driver.h ../common/view.h
247  
248 < source.o:       source.h
248 > m_direct.o m_mirror.o m_mist.o dielectric.o \
249 > source.o srcsamp.o srcsupp.o virtuals.o:        source.h
250  
251 < cone.o data.o devcomm.o face.o image.o misc.o objset.o octree.o otypes.o \
252 < readobj.o readoct.o rview.o:    standard.h fvect.h
251 > cone.o data.o devcomm.o freeobjmem.o initotypes.o fprism.o \
252 > duphead.o octree.o:     ../common/standard.h ../common/mat4.h ../common/fvect.h
253  
254 + initotypes.o raytrace.o:        otspecial.h
255 +
256   sundev.o:       suntools.icon
257  
258 < image.o rpmain.o rtmain.o rvmain.o rpict.o:     view.h
258 > rpmain.o rtmain.o rvmain.o rpict.o:     ../common/view.h
259  
260   x10.o xtwind.o: xtwind.h
261  
262   x11.o x11twind.o: x11twind.h
263 +
264 + x11.o:  x11icon.h
265 +
266 + ambient.o ambcomp.o ambio.o lookamb.o:  ambient.h
267 +
268 + data.o rmain.o rpict.o rtrace.o rv2.o:  ../common/resolu.h
269 +
270 + aniso.o func.o m_brdf.o m_direct.o mx_data.o mx_func.o p_data.o \
271 + p_func.o t_data.o t_func.o:     func.h
272 +
273 + freeobjmem.o:   ../common/object.h
274 +
275 + devcomm.o:      ../common/vfork.h
276 +
277 + rtmain.o rpmain.o rvmain.o persist.o duphead.o rpict.o: ../common/paths.h

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines