freebsd-skq/lib/libc/Makefile.inc
Bruce Evans ae80efa54f Handle machine-dependent (m-d) (string) sources more automatically.
The names of m-d variants are now added (manually) to MDSRCS instead
of to SRCS, and the names of all machine-independent (m-i) variants
that can reasonably be replaced by an m-d variant are now added
(manually) to MISRCS instead of to SRCS, so that a simple substitution
can be used to discard the unused m-i variants.  MISRCS is potentially
all m-i sources, but the substitution is too simple to be fast, so
MISRCS should be kept reasonably small.

libc/Makefile.inc:
Do the substitution.

libc/i386/string/Makefile.inc:
Add to MDSRCS instead of to SRCS.  Add the names of all sources in this
directory, but no others.

libc/string/Makefile.inc
Add to MISRCS instead of to SRCS.  Add the names of all sources in this
directory.  Don't use (broken) explicit rules for special cases.
1997-10-16 13:46:50 +00:00

36 lines
1.2 KiB
Makefile

# $Id: Makefile.inc,v 1.2 1997/10/15 16:29:08 bde Exp $
#
# This file contains make rules that are shared by libc and libc_r.
#
.include "${.CURDIR}/../libc/db/Makefile.inc"
.include "${.CURDIR}/../libc/compat-43/Makefile.inc"
.include "${.CURDIR}/../libc/gen/Makefile.inc"
.include "${.CURDIR}/../libc/gmon/Makefile.inc"
.include "${.CURDIR}/../libc/locale/Makefile.inc"
.include "${.CURDIR}/../libc/net/Makefile.inc"
.include "${.CURDIR}/../libc/nls/Makefile.inc"
.include "${.CURDIR}/../libc/quad/Makefile.inc"
.include "${.CURDIR}/../libc/regex/Makefile.inc"
.include "${.CURDIR}/../libc/stdio/Makefile.inc"
.include "${.CURDIR}/../libc/stdlib/Makefile.inc"
.include "${.CURDIR}/../libc/stdtime/Makefile.inc"
.include "${.CURDIR}/../libc/string/Makefile.inc"
.include "${.CURDIR}/../libc/sys/Makefile.inc"
.include "${.CURDIR}/../libc/rpc/Makefile.inc"
.include "${.CURDIR}/../libc/xdr/Makefile.inc"
.if !defined(NO_YP_LIBC)
CFLAGS+= -DYP
.include "${.CURDIR}/../libc/yp/Makefile.inc"
.endif
# Append machine-dependent sources, then append machine-independent sources
# for which there is no machine-dependent variant.
.if !empty(MDSRCS)
SRCS+= ${MDSRCS}
.for _src in ${MISRCS}
.if ${MDSRCS:R:M${_src:R}} == ""
SRCS+= ${_src}
.endif
.endfor
.endif