]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - lib/Makefile
Don't build libdevdctl if MK_CXX is no
[FreeBSD/FreeBSD.git] / lib / Makefile
1 #       @(#)Makefile    8.1 (Berkeley) 6/4/93
2 # $FreeBSD$
3
4 .include <src.opts.mk>
5
6 # The SUBDIR_BOOTSTRAP list is a small set of libraries which are used by many
7 # of the other libraries.  These are built first with a .WAIT between them
8 # and the main list to avoid needing a SUBDIR_DEPEND line on every library
9 # naming just these few items.
10
11 SUBDIR_BOOTSTRAP= \
12         csu \
13         .WAIT \
14         libc \
15         libc_nonshared \
16         libcompiler_rt \
17         ${_libclang_rt} \
18         ${_libcplusplus} \
19         ${_libcxxrt} \
20         libelf \
21         msun
22
23 # The main list; please keep these sorted alphabetically.
24
25 SUBDIR= ${SUBDIR_BOOTSTRAP} \
26         .WAIT \
27         libalias \
28         libarchive \
29         ${_libatm} \
30         libauditd \
31         libbegemot \
32         ${_libblacklist} \
33         libblocksruntime \
34         ${_libbluetooth} \
35         ${_libbsnmp} \
36         libbsdstat \
37         libbsm \
38         libbz2 \
39         libcalendar \
40         libcam \
41         ${_libcasper} \
42         ${_libcom_err} \
43         libcompat \
44         libcrypt \
45         libdevctl \
46         ${_libdevdctl} \
47         libdevinfo \
48         libdevstat \
49         libdpv \
50         libdwarf \
51         libedit \
52         ${_libelftc} \
53         libevent \
54         libexecinfo \
55         libexpat \
56         libfetch \
57         libfigpar \
58         libgeom \
59         ${_libgpio} \
60         ${_libgssapi} \
61         ${_librpcsec_gss} \
62         ${_libiconv_modules} \
63         libipsec \
64         libjail \
65         libkiconv \
66         libkvm \
67         ${_libldns} \
68         liblzma \
69         ${_libmagic} \
70         libmemstat \
71         libmd \
72         ${_libmilter} \
73         ${_libmp} \
74         libmt \
75         ${_libnandfs} \
76         lib80211 \
77         libnetbsd \
78         ${_libnetgraph} \
79         ${_libngatm} \
80         libnv \
81         libopenbsd \
82         libopie \
83         libpam \
84         libpcap \
85         ${_libpe} \
86         libpjdlog \
87         ${_libpmc} \
88         ${_libproc} \
89         libprocstat \
90         ${_libradius} \
91         librpcsvc \
92         librt \
93         ${_librtld_db} \
94         libsbuf \
95         ${_libsdp} \
96         ${_libsm} \
97         libsmb \
98         ${_libsmdb} \
99         ${_libsmutil} \
100         libsqlite3 \
101         libstand \
102         libstdbuf \
103         libstdthreads \
104         libsysdecode \
105         libtacplus \
106         ${_libtelnet} \
107         ${_libthr} \
108         libthread_db \
109         libucl \
110         libufs \
111         libugidfw \
112         libulog \
113         ${_libunbound} \
114         ${_libusbhid} \
115         ${_libusb} \
116         libutil \
117         ${_libvgl} \
118         ${_libvmmapi} \
119         libwrap \
120         libxo \
121         liby \
122         ${_libypclnt} \
123         libz \
124         ncurses \
125         ${_atf} \
126         ${_clang} \
127         ${_cuse} \
128         ${_tests}
129
130 # Inter-library dependencies.  When the makefile for a library contains LDADD
131 # libraries, those libraries should be listed as build order dependencies here.
132
133 SUBDIR_DEPEND_libarchive= libz libbz2 libexpat liblzma libmd
134 SUBDIR_DEPEND_libatm= libmd
135 SUBDIR_DEPEND_libauditdm= libbsm
136 SUBDIR_DEPEND_libbsnmp= ${_libnetgraph}
137 SUBDIR_DEPEND_libc++:= libcxxrt
138 SUBDIR_DEPEND_libc= libcompiler_rt
139 SUBDIR_DEPEND_libcam= libsbuf
140 SUBDIR_DEPEND_libcasper= libnv
141 SUBDIR_DEPEND_libdevstat= libkvm
142 SUBDIR_DEPEND_libdpv= libfigpar ncurses libutil
143 SUBDIR_DEPEND_libedit= ncurses
144 SUBDIR_DEPEND_libgeom= libexpat libsbuf
145 SUBDIR_DEPEND_liblibrpcsec_gss= libgssapi
146 SUBDIR_DEPEND_libmagic= libz
147 SUBDIR_DEPEND_libmemstat= libkvm
148 SUBDIR_DEPEND_libopie= libmd
149 SUBDIR_DEPEND_libpam= libcrypt libopie ${_libradius} librpcsvc libtacplus libutil ${_libypclnt} ${_libcom_err} 
150 SUBDIR_DEPEND_libpjdlog= libutil
151 SUBDIR_DEPEND_libprocstat= libkvm libutil
152 SUBDIR_DEPEND_libradius= libmd
153 SUBDIR_DEPEND_libsmb= libkiconv
154 SUBDIR_DEPEND_libtacplus= libmd
155 SUBDIR_DEPEND_libulog= libmd
156 SUBDIR_DEPEND_libunbound= ${_libldns}
157 SUBDIR_DEPEND_liblzma= ${_libthr}
158
159 # NB: keep these sorted by MK_* knobs
160
161 .if ${MK_ATM} != "no"
162 _libngatm=      libngatm
163 .endif
164
165 .if ${MK_BLACKLIST} != "no"
166 _libblacklist=  libblacklist
167 .endif
168
169 .if ${MK_BLUETOOTH} != "no"
170 _libbluetooth=  libbluetooth
171 _libsdp=        libsdp
172 .endif
173
174 .if ${MK_BSNMP} != "no"
175 _libbsnmp=      libbsnmp
176 .endif
177
178 .if ${MK_CASPER} != "no"
179 _libcasper=     libcasper
180 .endif
181
182 .if ${MK_CLANG} != "no" && !defined(COMPAT_32BIT) && !defined(COMPAT_SOFTFP)
183 _clang=         clang
184 .endif
185
186 .if ${MK_CUSE} != "no"
187 _cuse=          libcuse
188 .endif
189
190 .if ${MK_CXX} != "no"
191 _libdevdctl=    libdevdctl
192 .endif
193
194 .if ${MK_TOOLCHAIN} != "no"
195 _libelftc=      libelftc
196 _libpe=         libpe
197 .endif
198
199 .if ${MK_FILE} != "no"
200 _libmagic=      libmagic
201 .endif
202
203 .if ${MK_GPIO} != "no"
204 _libgpio=       libgpio
205 .endif
206
207 .if ${MK_GSSAPI} != "no"
208 _libgssapi=     libgssapi
209 _librpcsec_gss= librpcsec_gss
210 .endif
211
212 .if ${MK_ICONV} != "no"
213 _libiconv_modules=      libiconv_modules
214 .endif
215
216 .if ${MK_KERBEROS_SUPPORT} != "no"
217 _libcom_err= libcom_err
218 .endif
219
220 .if ${MK_LDNS} != "no"
221 _libldns=       libldns
222 .endif
223
224 # The libraries under libclang_rt can only be built by clang, and only make
225 # sense to build when clang is enabled at all.  Furthermore, they can only be
226 # built for certain architectures.
227 .if ${MK_CLANG} != "no" && ${COMPILER_TYPE} == "clang" && \
228     (${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \
229     (${MACHINE_CPUARCH} == "arm" && ${MACHINE_ARCH} != "armeb") || \
230     (${MACHINE_CPUARCH} == "i386"))
231 _libclang_rt=   libclang_rt
232 .endif
233
234 .if ${MK_LIBCPLUSPLUS} != "no"
235 _libcxxrt=      libcxxrt
236 _libcplusplus=  libc++
237 .endif
238
239 .if ${MK_LIBTHR} != "no"
240 _libthr=        libthr
241 .endif
242
243 .if ${MK_NAND} != "no"
244 _libnandfs=     libnandfs
245 .endif
246
247 .if ${MK_NETGRAPH} != "no"
248 _libnetgraph=   libnetgraph
249 .endif
250
251 .if ${MK_NIS} != "no"
252 _libypclnt=     libypclnt
253 .endif
254
255 .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64"
256 _libvgl=        libvgl
257 _libproc=       libproc
258 _librtld_db=    librtld_db
259 .endif
260
261 .if ${MACHINE_CPUARCH} == "amd64"
262 .if ${MK_BHYVE} != "no"
263 _libvmmapi=     libvmmapi
264 .endif
265 .endif
266
267 .if ${MACHINE_CPUARCH} == "mips"
268 _libproc=       libproc
269 _librtld_db=    librtld_db
270 .endif
271
272 .if ${MACHINE_CPUARCH} == "powerpc"
273 _libproc=       libproc
274 _librtld_db=    librtld_db
275 .endif
276
277 .if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "arm" || \
278     ${MACHINE_CPUARCH} == "riscv"
279 _libproc=       libproc
280 _librtld_db=    librtld_db
281 .endif
282
283 .if ${MK_OPENSSL} != "no"
284 _libmp=         libmp
285 .endif
286
287 .if ${MK_PMC} != "no"
288 _libpmc=        libpmc
289 .endif
290
291 .if ${MK_RADIUS_SUPPORT} != "no"
292 _libradius=     libradius
293 .endif
294
295 .if ${MK_SENDMAIL} != "no"
296 _libmilter=     libmilter
297 _libsm=         libsm
298 _libsmdb=       libsmdb
299 _libsmutil=     libsmutil
300 .endif
301
302 .if ${MK_TELNET} != "no"
303 _libtelnet=     libtelnet
304 .endif
305
306 .if ${MK_TESTS_SUPPORT} != "no"
307 _atf=           atf
308 .endif
309 .if ${MK_TESTS} != "no"
310 _tests=         tests
311 .endif
312
313 .if ${MK_UNBOUND} != "no"
314 _libunbound=    libunbound
315 .endif
316
317 .if ${MK_USB} != "no"
318 _libusbhid=     libusbhid
319 _libusb=        libusb
320 .endif
321
322 .if !make(install)
323 SUBDIR_PARALLEL=
324 .endif
325
326 .include <bsd.subdir.mk>