Makefile revision 1574
1231057Sdim#	@(#)Makefile	8.2 (Berkeley) 2/3/94
2231057Sdim#
3246259Sdim# All library objects contain sccsid strings by default; they may be
4246259Sdim# excluded as a space-saving measure.  To produce a library that does
5231057Sdim# not contain these strings, delete -DLIBC_SCCS and -DSYSLIBC_SCCS
6231057Sdim# from CFLAGS below.  To remove these strings from just the system call
7231057Sdim# stubs, remove just -DSYSLIBC_SCCS from CFLAGS.
8231057SdimLIB=c
9231057SdimCFLAGS+=-DLIBC_SCCS -DSYSLIBC_SCCS
10231057SdimAINC=	-I${.CURDIR}/${MACHINE}
11231057SdimCLEANFILES+=tags
12231057Sdim
13231057Sdim.include "${.CURDIR}/db/Makefile.inc"
14231057Sdim.include "${.CURDIR}/compat-43/Makefile.inc"
15249423Sdim.include "${.CURDIR}/gen/Makefile.inc"
16231057Sdim.include "${.CURDIR}/gmon/Makefile.inc"
17231057Sdim.include "${.CURDIR}/locale/Makefile.inc"
18263508Sdim.include "${.CURDIR}/net/Makefile.inc"
19243830Sdim.include "${.CURDIR}/quad/Makefile.inc"
20263508Sdim.include "${.CURDIR}/regex/Makefile.inc"
21263508Sdim.include "${.CURDIR}/stdio/Makefile.inc"
22263508Sdim.include "${.CURDIR}/stdlib/Makefile.inc"
23231057Sdim.include "${.CURDIR}/string/Makefile.inc"
24231057Sdim.include "${.CURDIR}/sys/Makefile.inc"
25
26KQSRCS=	adddi3.c anddi3.c ashldi3.c ashrdi3.c cmpdi2.c divdi3.c iordi3.c \
27	lshldi3.c lshrdi3.c moddi3.c muldi3.c negdi2.c notdi2.c qdivrem.c \
28	subdi3.c ucmpdi2.c udivdi3.c umoddi3.c xordi3.c
29KSRCS=	bcmp.c ffs.c index.c mcount.c rindex.c strcat.c strcmp.c strcpy.c \
30	strlen.c strncpy.c
31
32libkern: libkern.gen libkern.${MACHINE}
33
34libkern.gen: ${KQSRCS} ${KSRCS}
35	cp -p ${.CURDIR}/quad/quad.h ${.ALLSRC} /sys/libkern
36
37libkern.${MACHINE}:: ${KMSRCS}
38.if defined(KMSRCS) && !empty(KMSRCS)
39	cp -p ${.ALLSRC} /sys/libkern/${MACHINE}
40.endif
41
42beforeinstall: tags
43	install -c -o bin -g bin -m 444 tags /var/db/libc.tags
44
45tags: ${SRCS}
46	ctags ${.ALLSRC:M*.c}
47	egrep -o "^ENTRY(.*)|^FUNC(.*)|^SYSCALL(.*)" ${.ALLSRC:M*.s} | \
48	    sed "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \
49	    >> tags; sort -o tags tags
50
51.include <bsd.lib.mk>
52