Makefile revision 1919
167754Smsmith#	@(#)Makefile	8.2 (Berkeley) 2/3/94
267754Smsmith#
367754Smsmith# All library objects contain sccsid strings by default; they may be
467754Smsmith# excluded as a space-saving measure.  To produce a library that does
567754Smsmith# not contain these strings, delete -DLIBC_SCCS and -DSYSLIBC_SCCS
667754Smsmith# from CFLAGS below.  To remove these strings from just the system call
767754Smsmith# stubs, remove just -DSYSLIBC_SCCS from CFLAGS.
867754SmsmithLIB=c
967754SmsmithCFLAGS+=-DLIBC_SCCS -DSYSLIBC_SCCS
1067754SmsmithAINC=	-I${.CURDIR}/${MACHINE}
11193267SjkimCLEANFILES+=tags
1270243SmsmithINSTALL_PIC_ARCHIVE=	yes
1367754Smsmith
1467754Smsmith.include "${.CURDIR}/db/Makefile.inc"
1567754Smsmith.include "${.CURDIR}/compat-43/Makefile.inc"
1667754Smsmith.include "${.CURDIR}/gen/Makefile.inc"
1767754Smsmith.include "${.CURDIR}/gmon/Makefile.inc"
1867754Smsmith.include "${.CURDIR}/locale/Makefile.inc"
1967754Smsmith.include "${.CURDIR}/net/Makefile.inc"
2067754Smsmith.include "${.CURDIR}/quad/Makefile.inc"
2167754Smsmith.include "${.CURDIR}/regex/Makefile.inc"
2267754Smsmith.include "${.CURDIR}/stdio/Makefile.inc"
2367754Smsmith.include "${.CURDIR}/stdlib/Makefile.inc"
2467754Smsmith.include "${.CURDIR}/string/Makefile.inc"
2567754Smsmith.include "${.CURDIR}/sys/Makefile.inc"
2667754Smsmith.include "${.CURDIR}/rpc/Makefile.inc"
2767754Smsmith.include "${.CURDIR}/xdr/Makefile.inc"
2867754Smsmith.if !defined(NO_YP_LIBC)
2967754SmsmithCFLAGS+= -DYP
3067754Smsmith.include "${.CURDIR}/yp/Makefile.inc"
3167754Smsmith.endif
3267754Smsmith
3367754SmsmithKQSRCS=	adddi3.c anddi3.c ashldi3.c ashrdi3.c cmpdi2.c divdi3.c iordi3.c \
3467754Smsmith	lshldi3.c lshrdi3.c moddi3.c muldi3.c negdi2.c notdi2.c qdivrem.c \
3567754Smsmith	subdi3.c ucmpdi2.c udivdi3.c umoddi3.c xordi3.c
3667754SmsmithKSRCS=	bcmp.c ffs.c index.c mcount.c rindex.c strcat.c strcmp.c strcpy.c \
3767754Smsmith	strlen.c strncpy.c
3867754Smsmith
3967754Smsmithlibkern: libkern.gen libkern.${MACHINE}
4067754Smsmith
4167754Smsmithlibkern.gen: ${KQSRCS} ${KSRCS}
4267754Smsmith	cp -p ${.CURDIR}/quad/quad.h ${.ALLSRC} /sys/libkern
4367754Smsmith
4467754Smsmithlibkern.${MACHINE}:: ${KMSRCS}
4567754Smsmith.if defined(KMSRCS) && !empty(KMSRCS)
4667754Smsmith	cp -p ${.ALLSRC} /sys/libkern/${MACHINE}
4767754Smsmith.endif
4867754Smsmith
4967754Smsmith#beforeinstall: tags
5067754Smsmith#	install -c -o bin -g bin -m 444 tags /var/db/libc.tags
5167754Smsmith
5267754Smsmithtags: ${SRCS}
5367754Smsmith	ctags ${.ALLSRC:M*.c}
5467754Smsmith	egrep -o "^ENTRY(.*)|^FUNC(.*)|^SYSCALL(.*)" ${.ALLSRC:M*.s} | \
5567754Smsmith	    sed "s;\([^:]*\):\([^(]*\)(\([^, )]*\)\(.*\);\3 \1 /^\2(\3\4$$/;" \
5667754Smsmith	    >> tags; sort -o tags tags
5767754Smsmith
5867754Smsmith.include <bsd.lib.mk>
5967754Smsmith