1#!/bin/sh
2#
3#
4# This is an exmaple of a Universal compiler:
5#
6#	carreras --> is a Silicon Graphics machine
7#	caballe  --> is an IBM AIX
8#	<others> --> ... ok, others! ...
9#
10
11# Compiler options ( only C-O-M-P-I-L-E-R, not LUG options ).
12#
13CFLAGS = $(INCS) +z +O3 -Aa -D_INCLUDE_POSIX_SOURCE -D_INCLUDE_XOPEN_SOURCE
14
15#
16# Location of LUG header files.
17#
18LUGINC = -I../include
19LUGLIB = -L.. -llug
20
21#
22# If you have intalled the Utah Raster Toolkit library define
23# next variables, example:
24#
25#       URTINC = -I/remote/carreras/usr/people/nuevos/correo/urt/include
26#       URTDEF = -DiRLE
27#
28# , or leave undefined if you don't have it.
29#
30URTINC = -I/usr/local/include/urt
31URTLIB =-L/usr/remote/lib9/X11/urt -lrle
32URTDEF = -DiRLE
33
34#
35# If you have intalled the Sam Leffler's TIFF library define
36# next variables, example:
37#
38#       TIFFINC = -I/remote/carreras/usr/people/nuevos/correo/libtiff/include
39#       TIFFDEF = -DiTIFF
40#
41# , or leave undefined if you don't have it.
42#
43TIFFINC = -I/usr/local/include/tiff
44TIFFLIB = -L/usr/remote/lib9/tiff -ltiff
45TIFFDEF = -DiTIFF
46
47#
48# If you have intalled the JPEG library define
49# next variables, example:
50#
51#       JPEGINC = -I/remote/carreras/usr/people/nuevos/correo/jpeg/src
52#       JPEGDEF = -DiJPEG
53#
54# , or leave undefined if you don't have it.
55#
56JPEGINC = -I/usr/local/include/jpeg
57JPEGLIB = -L/usr/remote/lib9/jpeg4A -ljpeg
58JPEGDEF = -DiJPEG
59
60#
61# If your machine is a SGI computer define next variables, ... ok,
62# ok, an example:
63#
64#       SGIINC = -I/usr/include/gl
65#       SGIDEF = -DiSGI
66#
67# , else leave undefined.
68#
69SGIINC =
70SGIDEF =
71
72#
73# Define what kind of viwer you'll support. Options are:
74#
75#       Machine                  Add
76#       -------                  ---
77#       hp9000                  -DiHP
78#       sgi/aix                 -DiGL
79#       pc                      -DiPC
80#       x11                     -DiX11
81#       vfr ( sgi )             -DiVFR   <-- SGI's Video Framer needs hardware
82#       linux			-DiLINUX
83#
84# Probably, also you'll need give a path to the headers.
85#
86# And example: we have a SGI with X11 and a Video FRamer, so
87# we define...
88#
89#       VIEWDEF = -DiGL -DiVFR
90#       VIEWINC = -I/usr/include/gl -I/usr/video/vfr/src/inc
91#
92VIEWINC = -I/usr/include/X11R5
93VIEWLIB = -L/usr/lib/X11R5 -lX11
94VIEWDEF = -DiX11
95
96#
97# Final includes ( don't touch this ! ).
98#
99INCS = $(LUGINC) $(URTINC) $(TIFFINC) $(JPEGINC) $(SGIINC) $(VIEWINC)
100LIBS = $(LUGLIB) $(URTLIB) $(TIFFLIB) $(JPEGLIB) $(VIEWLIB)
101DEFS =           $(URTDEF) $(TIFFDEF) $(JPEGDEF) $(SGIDEF) $(VIEWDEF)
102
103all: cabezon fade fademask fadesec hf2gif lugcnv raindrops senoidal siluet \
104      sx11 zoomlug
105
106fade: fade.o
107	cc -o $@ fade.o $(LIBS)
108
109cabezon: cabezon.o
110	cc -o $@ cabezon.o $(LIBS)
111
112fademask: fademask.o
113	cc -o $@ fademask.o $(LIBS)
114
115fadesec: fadesec.o
116	cc -o $@ fadesec.o $(LIBS)
117
118hf2gif: hf2gif.o
119	cc -o $@ hf2gif.o $(LIBS)
120
121lugcnv: lugcnv.o
122	cc -o $@ lugcnv.o $(LIBS)
123
124raindrops: raindrops.o
125	cc -o $@ raindrops.o $(LIBS) -lm
126
127senoidal: senoidal.o
128	cc -o $@ senoidal.o $(LIBS) -lm
129
130shp: shp.o
131	cc -o $@ shp.o $(LIBS)
132
133siluet: siluet.o
134	cc -o $@ siluet.o $(LIBS)
135
136slinux: slinux.o
137	cc -o $@ slinux.o $(LIBS)
138
139spc: spc.o
140	cc -o $@ spc.o $(LIBS)
141
142spcfade: spcfade.o
143	cc -o $@ spcfade.o $(LIBS)
144
145ssgi: ssgi.o
146	cc -o $@ ssgi.o $(LIBS)
147
148sx11: sx11.o
149	cc -o $@ sx11.o $(LIBS)
150
151tovision: tovision.o
152	cc -o $@ tovision.o $(LIBS)
153
154zoomlug: zoomlug.o
155	cc -o $@ zoomlug.o $(LIBS)
156
157clean:
158	rm -f cabezon fade fademask fadesec hf2gif lugcnv raindrops senoidal \
159              shp siluet slinux spc spcfade ssgi sx11 tovision zoomlug *.o
160