xref: /dragonfly/lib/libc/Makefile.inc (revision f9993810)
1# $FreeBSD: src/lib/libc/Makefile.inc,v 1.5 1999/08/27 23:58:06 peter Exp $
2#
3# This file contains make rules that are shared by libc and libc_rtld.
4#
5# Define (empty) variables so that make doesn't give substitution
6# errors if the included makefiles don't change these:
7MDSRCS=
8MISRCS=
9MDASM=
10MIASM=
11NOASM=
12
13WARNS=2
14
15# for now do not let the use of -flto (check -plugin-opt=-pass-through=-lc !)
16.if ${CFLAGS:M-flto}
17CFLAGS+=	-fno-lto
18LDFLAGS+=	-flto
19.endif
20
21.if ${LIB} == "c"
22.include "${.CURDIR}/../libc/${MACHINE_ARCH}/Makefile.inc"
23
24.include "${.CURDIR}/../libc/citrus/Makefile.inc"
25.include "${.CURDIR}/../libc/compat-43/Makefile.inc"
26.include "${.CURDIR}/../libc/db/Makefile.inc"
27.include "${.CURDIR}/../libc/gdtoa/Makefile.inc"
28.include "${.CURDIR}/../libc/gen/Makefile.inc"
29.include "${.CURDIR}/../libc/gmon/Makefile.inc"
30.include "${.CURDIR}/../libc/iconv/Makefile.inc"
31.include "${.CURDIR}/../libc/inet/Makefile.inc"
32.include "${.CURDIR}/../libc/isc/Makefile.inc"
33.include "${.CURDIR}/../libc/locale/Makefile.inc"
34.include "${.CURDIR}/../libc/nameser/Makefile.inc"
35.include "${.CURDIR}/../libc/net/Makefile.inc"
36.include "${.CURDIR}/../libc/nls/Makefile.inc"
37.include "${.CURDIR}/../libc/resolv/Makefile.inc"
38.include "${.CURDIR}/../libc/rpc/Makefile.inc"
39.include "${.CURDIR}/../libc/secure/Makefile.inc"
40.include "${.CURDIR}/../libc/stdio/Makefile.inc"
41.include "${.CURDIR}/../libc/stdlib/Makefile.inc"
42.include "${.CURDIR}/../libc/stdtime/Makefile.inc"
43.include "${.CURDIR}/../libc/string/Makefile.inc"
44.include "${.CURDIR}/../libc/sys/Makefile.inc"
45.include "${.CURDIR}/../libc/sysvipc/Makefile.inc"
46.include "${.CURDIR}/../libc/tre-regex/Makefile.inc"
47.include "${.CURDIR}/../libc/upmap/Makefile.inc"
48.include "${.CURDIR}/../libc/uuid/Makefile.inc"
49.include "${.CURDIR}/../libc/xdr/Makefile.inc"
50.if !defined(NO_YP_LIBC)
51CFLAGS+= -DYP
52.include "${.CURDIR}/../libc/yp/Makefile.inc"
53.endif
54.if defined(WANT_HESIOD)
55CFLAGS+= -DHESIOD
56.endif
57.if !defined(NO_NS_CACHING)
58CFLAGS+= -DNS_CACHING
59.endif
60.elif ${LIB} == "c_rtld"
61.include "${.CURDIR}/../libc/${MACHINE_ARCH}/Makefile.inc"
62
63.include "${.CURDIR}/../libc/gdtoa/Makefile.inc"
64.include "${.CURDIR}/../libc/gen/Makefile.inc"
65.include "${.CURDIR}/../libc/locale/Makefile.inc"
66.include "${.CURDIR}/../libc/net/Makefile.inc"
67.include "${.CURDIR}/../libc/stdio/Makefile.inc"
68.include "${.CURDIR}/../libc/stdlib/Makefile.inc"
69.include "${.CURDIR}/../libc/stdtime/Makefile.inc"
70.include "${.CURDIR}/../libc/string/Makefile.inc"
71.include "${.CURDIR}/../libc/sys/Makefile.inc"
72.include "${.CURDIR}/../libc/upmap/Makefile.inc"
73.endif
74
75# If there are no machine dependent sources, append all the
76# machine-independent sources:
77.if empty(MDSRCS)
78SRCS+=	${MISRCS}
79.else
80# Append machine-dependent sources, then append machine-independent sources
81# for which there is no machine-dependent variant.
82SRCS+=	${MDSRCS}
83.for _src in ${MISRCS}
84.if ${MDSRCS:R:M${_src:R}} == ""
85SRCS+=	${_src}
86.endif
87.endfor
88.endif
89