note that _getshort used by sendmail
[unix-history] / usr / src / lib / libterm / Makefile
CommitLineData
6468808a 1#
35378dd8 2# Copyright (c) 1987 Regents of the University of California.
6468808a
DF
3# All rights reserved. The Berkeley software License Agreement
4# specifies the terms and conditions for redistribution.
5#
1db24759 6# @(#)Makefile 5.3 (Berkeley) %G%
0b095c72
SL
7#
8CFLAGS= -O -DCM_N -DCM_GT -DCM_B -DCM_D
35378dd8 9LIBC= /lib/libc.a
87e481ed
SL
10SRCS= termcap.c tgoto.c tputs.c
11OBJS= termcap.o tgoto.o tputs.o
0b095c72
SL
12
13.c.o:
35378dd8
KB
14 ${CC} ${CFLAGS} -c -p $*.c
15 ld -x -r -o profiled/$*.o $*.o
16 ${CC} ${CFLAGS} -c $*.c
17 ld -X -r $*.o
0b095c72
SL
18 mv a.out $*.o
19
35378dd8
KB
20all: termcap.a termcap_p.a
21
87e481ed
SL
22termcap.a termcap_p.a: ${OBJS}
23 ar cr termcap.a ${OBJS}
24 cd profiled; ar cr ../termcap_p.a ${OBJS}
0b095c72 25
1db24759
JK
26test:
27 ranlib termcap.a
28 ${CC} ${CFLAGS} -o tc1 tc1.c termcap.a
29 ${CC} ${CFLAGS} -o tc2 tc2.c termcap.a
30 ${CC} ${CFLAGS} -o tc3 tc3.c termcap.a
31
35378dd8
KB
32clean: FRC
33 rm -f ${OBJS} core profiled/*.o termcap.a termcap_p.a
34
35depend: FRC
36 mkdep ${CFLAGS} ${SRCS}
37
38install: FRC
39 install -o bin -g bin -m 644 termcap.a ${DESTDIR}/usr/lib/libtermcap.a
40 rm -f ${DESTDIR}/usr/lib/libtermlib.a
0b095c72
SL
41 ln ${DESTDIR}/usr/lib/libtermcap.a ${DESTDIR}/usr/lib/libtermlib.a
42 ranlib ${DESTDIR}/usr/lib/libtermcap.a
35378dd8
KB
43 install -o bin -g bin -m 644 termcap_p.a ${DESTDIR}/usr/lib/libtermcap_p.a
44 rm -f ${DESTDIR}/usr/lib/libtermlib_p.a
0b095c72
SL
45 ln ${DESTDIR}/usr/lib/libtermcap_p.a ${DESTDIR}/usr/lib/libtermlib_p.a
46 ranlib ${DESTDIR}/usr/lib/libtermcap_p.a
47
35378dd8
KB
48lint: FRC
49 lint ${CFLAGS} ${SRCS}
50
51tags: FRC
52 ctags ${SRCS}
53
54FRC:
55
56# DO NOT DELETE THIS LINE -- mkdep uses it.
57# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
58
59termcap.o: termcap.c /usr/include/ctype.h
60tgoto.o: tgoto.c
61tputs.o: tputs.c /usr/include/sgtty.h /usr/include/sys/ioctl.h
62tputs.o: /usr/include/sys/ttychars.h /usr/include/sys/ttydev.h
63tputs.o: /usr/include/ctype.h
64
65# IF YOU PUT ANYTHING HERE IT WILL GO AWAY