Makefile revision 7421
1#	@(#)Makefile	8.2 (Berkeley) 2/3/94
2#
3# All library objects contain rcsid strings by default; they may be
4# excluded as a space-saving measure.  To produce a library that does
5# not contain these strings, delete -DLIBC_RCS and -DSYSLIBC_RCS
6# from CFLAGS below.  To remove these strings from just the system call
7# stubs, remove just -DSYSLIBC_RCS from CFLAGS.
8LIB=c
9SHLIB_MAJOR= 2
10SHLIB_MINOR= 1
11CFLAGS+=-DLIBC_RCS -DSYSLIBC_RCS
12AINC=	-I${.CURDIR}/${MACHINE}
13CLEANFILES+=tags
14INSTALL_PIC_ARCHIVE=	yes
15PRECIOUSLIB=	yes
16
17.include "${.CURDIR}/db/Makefile.inc"
18.include "${.CURDIR}/compat-43/Makefile.inc"
19.include "${.CURDIR}/gen/Makefile.inc"
20.include "${.CURDIR}/gmon/Makefile.inc"
21.include "${.CURDIR}/locale/Makefile.inc"
22.include "${.CURDIR}/net/Makefile.inc"
23.include "${.CURDIR}/quad/Makefile.inc"
24.include "${.CURDIR}/regex/Makefile.inc"
25.include "${.CURDIR}/stdio/Makefile.inc"
26.include "${.CURDIR}/stdlib/Makefile.inc"
27.include "${.CURDIR}/stdtime/Makefile.inc"
28.include "${.CURDIR}/string/Makefile.inc"
29.include "${.CURDIR}/sys/Makefile.inc"
30.include "${.CURDIR}/rpc/Makefile.inc"
31.include "${.CURDIR}/xdr/Makefile.inc"
32.if !defined(NO_YP_LIBC)
33CFLAGS+= -DYP
34.include "${.CURDIR}/yp/Makefile.inc"
35.endif
36.include "${.CURDIR}/${MACHINE}/sys/Makefile.inc"
37
38KQSRCS=	adddi3.c anddi3.c ashldi3.c ashrdi3.c cmpdi2.c divdi3.c iordi3.c \
39	lshldi3.c lshrdi3.c moddi3.c muldi3.c negdi2.c notdi2.c qdivrem.c \
40	subdi3.c ucmpdi2.c udivdi3.c umoddi3.c xordi3.c
41KSRCS=	bcmp.c ffs.c index.c mcount.c rindex.c strcat.c strcmp.c strcpy.c \
42	strlen.c strncpy.c
43
44libkern: libkern.gen libkern.${MACHINE}
45
46libkern.gen: ${KQSRCS} ${KSRCS}
47	cp -p ${.CURDIR}/quad/quad.h ${.ALLSRC} /sys/libkern
48
49libkern.${MACHINE}:: ${KMSRCS}
50.if defined(KMSRCS) && !empty(KMSRCS)
51	cp -p ${.ALLSRC} /sys/libkern/${MACHINE}
52.endif
53
54#beforeinstall: tags
55#	install -c -o bin -g bin -m 444 tags /var/db/libc.tags
56
57tags: ${SRCS}
58	ctags ${.ALLSRC:M*.c}
59	egrep -o "^ENTRY(.*)|^FUNC(.*)|^SYSCALL(.*)" ${.ALLSRC:M*.s} | \
60	    sed "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \
61	    >> tags; sort -o tags tags
62
63.include <bsd.lib.mk>
64