(no message)
[unix-history] / usr / src / usr.bin / uucp / Makefile
CommitLineData
ed6d23c8 1# Makefile 5.5 83/07/18
11ece1e5
SL
2#
3# This version expects the 4.2BSD directory reading routines to
4# located in libc.a. If they aren't, augment LIBS. Also, LIBS
5# can be set to reference other object modules and libraries needed
6# by uucico, such as -lunet (needed when UNET is defined).
7#
8# Common object files are assembled into a library {uulib.a}
9#
10ALL= uucp uux uuxqt uucico uulog uuclean uuname uupoll uusnap \
11 uuencode uudecode uusend
12# Common object files placed in uulib.a
13COMMON= anlwrk.o anyread.o assert.o cfgets.o chkpth.o \
14 cpmv.o expfile.o gename.o getargs.o getopt.o getprm.o \
15 getpw.o getpwinfo.o gio.o gnamef.o gnxseq.o gwd.o imsg.o \
16 index.o lastpart.o logent.o mailst.o pk0.o pk1.o prefix.o \
17 sdmail.o setline.o shio.o subdir.o sysacct.o systat.o ulockf.o \
18 uucpname.o versys.o xqt.o uucpdefs.o
19DESTDIR=
20OWNER= uucp
21GROUP= daemon
22CFLAGS= -O
23LDFLAGS=
24LIBS=
25LIBDIR= /usr/lib/uucp
26BIN= /usr/bin
27PUBDIR= /usr/spool/uucppublic
28SPOOL= /usr/spool/uucp
29XQTDIR= /usr/spool/uucp/XTMP
30# The six subdirs {not counting XTMP}. The order of the D. files is crucial!
31SUBDIRS=C. D.`uuname -l`X D.`uuname -l` D. X. TM.
32PKON= pkon.o
33IOCTL=
11cfcb47 34# for make depend
e880f836 35UNDEF= -UNDIR -UUNET -USYSIII -UUNAME -UCCWHOAMI -UGETMYHNAME -UDATAKIT
11ece1e5
SL
36
37all: ${ALL}
38
39uucp: uucp.o uulib.a
40 ${CC} -o uucp ${LDFLAGS} uucp.o uulib.a
41
42uux: uux.o uulib.a
43 ${CC} -o uux ${LDFLAGS} uux.o uulib.a
44
45uuxqt: uuxqt.o uulib.a
46 ${CC} -o uuxqt ${LDFLAGS} uuxqt.o uulib.a ${LIBS}
47
48uucico: cico.o cntrl.o conn.o condevs.o gnsys.o ${IOCTL} ${PKON} uulib.a
49 ${CC} -o uucico ${LDFLAGS} cico.o cntrl.o conn.o condevs.o \
46de79ef 50 gnsys.o ${IOCTL} ${PKON} uulib.a ${LIBS}
11ece1e5
SL
51
52uulog: uulog.o uulib.a
53 ${CC} -o uulog ${LDFLAGS} uulog.o uulib.a
54
55uuclean: uuclean.o uulib.a
56 ${CC} -o uuclean ${LDFLAGS} uuclean.o uulib.a
57
58uuname: uuname.o uulib.a
59 ${CC} -o uuname ${LDFLAGS} uuname.o uulib.a
60
61uupoll: uupoll.o uulib.a
62 ${CC} -o uupoll ${LDFLAGS} uupoll.o uulib.a
63
64uusnap: uusnap.o uulib.a
65 ${CC} -o uusnap ${LDFLAGS} uusnap.o uulib.a ${LIBS}
66
67uuencode: uuencode.o uulib.a
68 ${CC} -o uuencode ${LDFLAGS} uuencode.o uulib.a
69
70uudecode: uudecode.o uulib.a
71 ${CC} -o uudecode ${LDFLAGS} uudecode.o uulib.a
72
73uusend: uusend.o uulib.a
74 ${CC} -o uusend ${LDFLAGS} uusend.o uulib.a
75
76# Note: mode 700 on ${LIBDIR} would be safer.
77# Also, L.sys etc should be 600.
78mkdirs:
79 -mkdir ${DESTDIR}/${LIBDIR}
80 chmod 755 ${DESTDIR}/${LIBDIR}
81 chown ${OWNER} ${DESTDIR}/${LIBDIR}
82 chgrp ${GROUP} ${DESTDIR}/${LIBDIR}
83 -mkdir ${DESTDIR}/${SPOOL}
84 chmod 755 ${DESTDIR}/${SPOOL}
85 chown ${OWNER} ${DESTDIR}/${SPOOL}
86 chgrp ${GROUP} ${DESTDIR}/${SPOOL}
87 -mkdir ${DESTDIR}/${PUBDIR}
88 chmod 777 ${DESTDIR}/${PUBDIR}
89 chown ${OWNER} ${DESTDIR}/${PUBDIR}
90 chgrp ${GROUP} ${DESTDIR}/${PUBDIR}
91 -mkdir ${DESTDIR}/${XQTDIR}
92 chmod 755 ${DESTDIR}/${XQTDIR}
93 chown ${OWNER} ${DESTDIR}/${XQTDIR}
94 chgrp ${GROUP} ${DESTDIR}/${XQTDIR}
95 cd ${DESTDIR}/${SPOOL}; for i in ${SUBDIRS}; do \
96 mkdir $$i; \
11cfcb47 97 chown ${OWNER} $$i; chgrp ${GROUP} $$i; chmod 755 $$i; \
11ece1e5
SL
98 done
99
100# The lorder...tsort below is for systems w/o ranlib
101# But it doesnt hurt to use it. Ignore the spurious "cycle" messages
102uulib.a: ${COMMON}
103 rm -f $@
104 ar cr $@ `lorder ${COMMON} | tsort`
105 ranlib $@
106
107install: all
108 chown ${OWNER} ${DESTDIR}/${LIBDIR}
109 chgrp ${GROUP} ${DESTDIR}/${LIBDIR}
110 chmod 755 ${DESTDIR}/${LIBDIR}
111 install -s -m 6111 -o ${OWNER} -g ${GROUP} uucp ${DESTDIR}/${BIN}/uucp
112 install -s -m 6111 -o ${OWNER} -g ${GROUP} uux ${DESTDIR}/${BIN}/uux
113 : chmod u+t ${BIN}/uux; : this helps PDPs
114 install -s -m 6110 -o ${OWNER} -g ${GROUP} \
115 uuxqt ${DESTDIR}/${LIBDIR}/uuxqt
116 : chmod u+t ${LIBDIR}/uuxqt; : this helps PDPs
117 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
118 uucico ${DESTDIR}/${LIBDIR}/uucico
119 : chmod u+t ${LIBDIR}/uucico; : this helps PDPs if uucico is pure
120 install -s -m 6111 -o ${OWNER} -g ${GROUP} uulog ${DESTDIR}/${BIN}/uulog
121 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
122 uuclean ${DESTDIR}/${LIBDIR}/uuclean
123 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
124 uuname ${DESTDIR}/${BIN}/uuname
125 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
126 uupoll ${DESTDIR}/${BIN}/uupoll
127 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
128 uusnap ${DESTDIR}/${BIN}/uusnap
ed6d23c8
SL
129 install -s uuencode ${DESTDIR}/${BIN}/uuencode
130 install -s uudecode ${DESTDIR}/${BIN}/uudecode
11ece1e5
SL
131 install -s -m 6111 -o ${OWNER} -g ${GROUP} \
132 uusend ${DESTDIR}/${BIN}/uusend
133 rm -f ${DESTDIR}/${BIN}/ruusend
134 ln ${DESTDIR}/${BIN}/uusend ${DESTDIR}/${BIN}/ruusend
135
136clean:
137 rm -f *.o ${ALL} uulib.a
138
139depend:
140 for i in *.c; do \
141 (echo `basename $$i .c`.o: $$i >>makedep; \
11cfcb47 142 unifdef ${UNDEF} $$i | \
11ece1e5
SL
143 /bin/grep '^#[ ]*include' | sed \
144 -e '/\.\.\/h/d' \
145 -e 's,<\(.*\)>,"/usr/include/\1",' \
146 -e 's/^[^"]*"\([^"]*\)".*/'"$$i"': \1/' \
147 -e 's/\.c/.o/' >>makedep); done
148 echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep
149 echo '$$r makedep' >>eddep
150 echo 'w' >>eddep
151 cp Makefile Makefile.bak
152 ed - Makefile < eddep
153 rm eddep makedep
154 echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile
155 echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile
156 echo '# see make depend above' >> Makefile
157
158# DO NOT DELETE THIS LINE -- make depend uses it
159# DEPENDENCIES MUST END AT END OF FILE
160anlwrk.o: anlwrk.c
161anlwrk.o: uucp.h
162anlwrk.o: /usr/include/sys/types.h
163anlwrk.o: /usr/include/sys/stat.h
11cfcb47 164anlwrk.o: /usr/include/sys/dir.h
11ece1e5
SL
165anyread.o: anyread.c
166anyread.o: uucp.h
167anyread.o: /usr/include/sys/types.h
168anyread.o: /usr/include/sys/stat.h
169assert.o: assert.c
170assert.o: uucp.h
11cfcb47 171assert.o: /usr/include/sys/time.h
11ece1e5
SL
172assert.o: /usr/include/sys/types.h
173assert.o: /usr/include/errno.h
174cfgets.o: cfgets.c
175cfgets.o: /usr/include/stdio.h
176chkpth.o: chkpth.c
177chkpth.o: uucp.h
178chkpth.o: /usr/include/sys/types.h
179chkpth.o: /usr/include/sys/stat.h
180cico.o: cico.c
181cico.o: uucp.h
182cico.o: /usr/include/signal.h
183cico.o: /usr/include/setjmp.h
184cico.o: /usr/include/sys/types.h
11ece1e5
SL
185cico.o: /usr/include/sgtty.h
186cntrl.o: cntrl.c
187cntrl.o: uucp.h
188cntrl.o: /usr/include/sys/types.h
189cntrl.o: /usr/include/sys/stat.h
190condevs.o: condevs.c
191condevs.o: /usr/include/sys/types.h
192condevs.o: /usr/include/errno.h
193condevs.o: /usr/include/setjmp.h
194condevs.o: /usr/include/signal.h
195condevs.o: /usr/include/sgtty.h
196condevs.o: uucp.h
11cfcb47 197condevs.o: /usr/include/sys/time.h
11ece1e5
SL
198condevs.o: /usr/include/sys/timeb.h
199conn.o: conn.c
200conn.o: uucp.h
201conn.o: /usr/include/signal.h
202conn.o: /usr/include/setjmp.h
203conn.o: /usr/include/ctype.h
204conn.o: /usr/include/sys/types.h
11cfcb47 205conn.o: /usr/include/sys/time.h
11ece1e5 206conn.o: /usr/include/errno.h
11ece1e5
SL
207conn.o: /usr/include/sgtty.h
208cpmv.o: cpmv.c
209cpmv.o: uucp.h
210cpmv.o: /usr/include/sys/types.h
211cpmv.o: /usr/include/sys/stat.h
212expfile.o: expfile.c
213expfile.o: uucp.h
214expfile.o: /usr/include/sys/types.h
215expfile.o: /usr/include/sys/stat.h
216gename.o: gename.c
217gename.o: uucp.h
218getargs.o: getargs.c
219getargs.o: /usr/include/stdio.h
220getopt.o: getopt.c
221getopt.o: /usr/include/stdio.h
222getprm.o: getprm.c
223getprm.o: /usr/include/stdio.h
224getpw.o: getpw.c
11cfcb47 225getpw.o: /usr/include/stdio.h
11ece1e5
SL
226getpwinfo.o: getpwinfo.c
227getpwinfo.o: uucp.h
228getpwinfo.o: /usr/include/pwd.h
229gio.o: gio.c
230gio.o: pk.p
231gio.o: /usr/include/sys/types.h
232gio.o: pk.h
233gio.o: /usr/include/setjmp.h
234gio.o: uucp.h
235gnamef.o: gnamef.c
236gnamef.o: uucp.h
237gnamef.o: /usr/include/sys/types.h
11cfcb47 238gnamef.o: /usr/include/sys/dir.h
11ece1e5
SL
239gnsys.o: gnsys.c
240gnsys.o: uucp.h
241gnsys.o: /usr/include/sys/types.h
11cfcb47 242gnsys.o: /usr/include/sys/dir.h
11ece1e5
SL
243gnxseq.o: gnxseq.c
244gnxseq.o: uucp.h
245gnxseq.o: /usr/include/sys/types.h
11cfcb47 246gnxseq.o: /usr/include/sys/time.h
11ece1e5
SL
247gwd.o: gwd.c
248gwd.o: uucp.h
249gwd.o: /usr/include/signal.h
250imsg.o: imsg.c
251imsg.o: uucp.h
252index.o: index.c
253index.o: /usr/include/stdio.h
254ioctl.o: ioctl.c
255ioctl.o: uucp.h
256ioctl.o: /usr/include/sgtty.h
257lastpart.o: lastpart.c
258logent.o: logent.c
259logent.o: uucp.h
260logent.o: /usr/include/sys/types.h
11cfcb47 261logent.o: /usr/include/sys/time.h
11ece1e5
SL
262logent.o: /usr/include/sgtty.h
263mailst.o: mailst.c
264mailst.o: uucp.h
265pk0.o: pk0.c
266pk0.o: /usr/include/stdio.h
11ece1e5
SL
267pk0.o: pk.p
268pk0.o: /usr/include/sys/param.h
269pk0.o: pk.h
270pk0.o: /usr/include/sys/buf.h
271pk1.o: pk1.c
272pk1.o: /usr/include/stdio.h
11ece1e5
SL
273pk1.o: pk.p
274pk1.o: /usr/include/sys/param.h
275pk1.o: pk.h
276pk1.o: /usr/include/sys/buf.h
277pk1.o: /usr/include/setjmp.h
278pk1.o: /usr/include/signal.h
279pkon.o: pkon.c
280prefix.o: prefix.c
281sdmail.o: sdmail.c
282sdmail.o: uucp.h
283sdmail.o: /usr/include/pwd.h
284setline.o: setline.c
285setline.o: uucp.h
11ece1e5
SL
286shio.o: shio.c
287shio.o: uucp.h
288shio.o: /usr/include/signal.h
289subdir.o: subdir.c
290subdir.o: uucp.h
291sysacct.o: sysacct.c
292sysacct.o: /usr/include/sys/types.h
293systat.o: systat.c
294systat.o: uucp.h
295systat.o: /usr/include/sys/types.h
296ulockf.o: ulockf.c
297ulockf.o: uucp.h
298ulockf.o: /usr/include/sys/types.h
299ulockf.o: /usr/include/sys/stat.h
300uuclean.o: uuclean.c
301uuclean.o: uucp.h
302uuclean.o: /usr/include/signal.h
303uuclean.o: /usr/include/pwd.h
304uuclean.o: /usr/include/sys/types.h
305uuclean.o: /usr/include/sys/stat.h
11cfcb47 306uuclean.o: /usr/include/sys/dir.h
11ece1e5
SL
307uucp.o: uucp.c
308uucp.o: uucp.h
309uucp.o: /usr/include/sys/types.h
310uucp.o: /usr/include/sys/stat.h
311uucpdefs.o: uucpdefs.c
312uucpdefs.o: uucp.h
313uucpname.o: uucpname.c
314uucpname.o: uucp.h
315uucpname.o: /usr/include/sys/types.h
316uucpname.o: /usr/include/sys/stat.h
11ece1e5
SL
317uudecode.o: uudecode.c
318uudecode.o: /usr/include/stdio.h
319uudecode.o: /usr/include/pwd.h
320uudecode.o: /usr/include/sys/types.h
321uudecode.o: /usr/include/sys/stat.h
322uuencode.o: uuencode.c
323uuencode.o: /usr/include/stdio.h
324uuencode.o: /usr/include/sys/types.h
325uuencode.o: /usr/include/sys/stat.h
326uulog.o: uulog.c
327uulog.o: uucp.h
328uuname.o: uuname.c
329uuname.o: uucp.h
330uuname.o: /usr/include/signal.h
331uupoll.o: uupoll.c
332uupoll.o: uucp.h
333uusend.o: uusend.c
334uusend.o: /usr/include/stdio.h
335uusend.o: /usr/include/pwd.h
336uusend.o: /usr/include/sys/types.h
337uusend.o: /usr/include/sys/stat.h
338uusnap.o: uusnap.c
339uusnap.o: uucp.h
340uusnap.o: /usr/include/sys/types.h
341uusnap.o: /usr/include/sys/stat.h
11cfcb47 342uusnap.o: /usr/include/sys/dir.h
11ece1e5
SL
343uux.o: uux.c
344uux.o: uucp.h
345uuxqt.o: uuxqt.c
346uuxqt.o: uucp.h
347uuxqt.o: /usr/include/sys/types.h
348uuxqt.o: /usr/include/sys/stat.h
11cfcb47 349uuxqt.o: /usr/include/sys/dir.h
11ece1e5
SL
350versys.o: versys.c
351versys.o: uucp.h
352xqt.o: xqt.c
353xqt.o: uucp.h
354xqt.o: /usr/include/signal.h
355# DEPENDENCIES MUST END AT END OF FILE
356# IF YOU PUT STUFF HERE IT WILL GO AWAY
357# see make depend above