Remove building with NOCRYPTO option
[minix.git] / lib / Makefile
blobd40edd1daa2b545055c8b94902165ad8682aaa73
1 # $NetBSD: Makefile,v 1.235 2015/09/28 17:12:12 christos Exp $
2 # from: @(#)Makefile 5.25.1.1 (Berkeley) 5/7/91
4 .include <bsd.own.mk>
6 SUBDIR= csu .WAIT
8 .if (${MKGCC} != "no")
9 SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libgcc .WAIT
10 .endif
12 .if defined(__MINIX)
13 #LSC MINIX libc depends on
14 # - libmthread because of sys/lib/libunwind
15 SUBDIR+= .WAIT
17 SUBDIR+= ../minix/lib/libsys
18 SUBDIR+= ../minix/lib/libmthread
19 SUBDIR+= .WAIT
20 .endif # defined(__MINIX)
21 SUBDIR+= libc
22 SUBDIR+= .WAIT
24 .if defined(__MINIX)
25 SUBDIR+= ../minix/lib/libasyn \
26 ../minix/lib/libaudiodriver \
27 ../minix/lib/libbdev \
28 ../minix/lib/libblockdriver \
29 ../minix/lib/libchardriver \
30 ../minix/lib/libddekit \
31 ../minix/lib/libdevman \
32 ../minix/lib/libexec \
33 ../minix/lib/libfsdriver \
34 ../minix/lib/libinputdriver \
35 ../minix/lib/liblwip \
36 ../minix/lib/libminc \
37 ../minix/lib/libminixfs \
38 ../minix/lib/libnetdriver \
39 ../minix/lib/libsffs \
40 ../minix/lib/libsockdriver \
41 ../minix/lib/libsockevent \
42 ../minix/lib/libtimers \
43 ../minix/lib/libusb \
44 ../minix/lib/libvtreefs
46 .if (${HAVE_LIBGCC} == "no")
47 SUBDIR+= ../minix/lib/libgcc_s_empty
48 .endif
50 .if (${MACHINE_ARCH} == "i386")
51 SUBDIR+= ../minix/lib/libacpi \
52 ../minix/lib/libhgfs \
53 ../minix/lib/libvassert \
54 ../minix/lib/libvboxfs \
55 ../minix/lib/libvirtio
56 .endif
58 .if (${MACHINE_ARCH} == "earm")
59 SUBDIR+= ../minix/lib/libclkconf \
60 ../minix/lib/libgpio \
61 ../minix/lib/libi2cdriver
62 .endif
64 .if (${MKMAGIC} == "yes")
65 SUBDIR+= ../minix/lib/libmagicrt
66 .endif
68 .endif # defined(__MINIX)
70 # The SUBDIRs above are included here for completeness but should be built
71 # and installed prior to make(dependall) in this file, as libraries listed
72 # below will depend on versions from DESTDIR only.
75 SUBDIR+= i18n_module
77 SUBDIR+= \
78 libbz2 \
79 libcrypt \
80 libintl libkvm libm \
81 libpci libprop \
82 libpuffs librmt \
83 libtelnet libterminfo \
84 libutil libwrap libz
86 .if !defined(BSD_MK_COMPAT_FILE)
87 #SUBDIR+= libkern
88 .endif
90 .if (${MACHINE_CPU} == "arm" || ${MACHINE_CPU} == "aarch64")
91 LIBC_MACHINE_ARCH?=${MACHINE_ARCH}
92 LIBC_MACHINE_CPU?=${MACHINE_CPU}
93 .if ${LIBC_MACHINE_CPU} == "arm" && empty(LIBC_MACHINE_ARCH:M*hf*)
94 .if !defined(__MINIX)
95 SUBDIR+= libc_vfp
96 .endif # !defined(__MINIX)
97 .endif
98 .endif
99 .if (${MKRUMP} != "no")
100 SUBDIR+= librumpclient
101 .endif
102 .if (${MKSKEY} != "no")
103 SUBDIR+= libskey
104 .endif
106 .if (${MKMDNS} != "no")
107 SUBDIR+= ../external/apache2/mDNSResponder/lib
108 .endif
110 #SUBDIR+= ../external/bsd/am-utils/lib
111 SUBDIR+= ../external/bsd/blacklist/lib
113 SUBDIR+= ../external/bsd/flex/lib
114 #SUBDIR+= ../external/bsd/tre/lib
115 SUBDIR+= ../external/bsd/elftoolchain/lib/libelf
116 #SUBDIR+= ../external/bsd/liblzf/lib
117 SUBDIR+= ../external/bsd/libpcap/lib
119 .if ${MKSLJIT} != "no"
120 SUBDIR+= ../external/bsd/sljit/lib
121 SUBDIR+= libbpfjit
122 .endif
124 .if (${MKZFS} != "no")
125 SUBDIR+= ../external/cddl/osnet/lib/libavl
126 SUBDIR+= ../external/cddl/osnet/lib/libnvpair
127 SUBDIR+= ../external/cddl/osnet/lib/libumem
128 SUBDIR+= ../external/cddl/osnet/lib/libuutil
129 .endif
131 SUBDIR+= ../external/mit/expat/lib
133 SUBDIR+= ../external/public-domain/sqlite/lib
135 #SUBDIR+= ../gnu/lib/libmalloc
137 .if (${MKGCC} != "no")
138 . if !defined(__MINIX) || ${MKLIBSTDCXX} == "yes"
139 SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libobjc
140 SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libgomp
141 #SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libmudflap
142 #SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libmudflapth
143 . endif # !defined(__MINIX) || ${MKLIBSTDCXX} == "yes"
144 . if !defined(__MINIX) || ${MKLIBSTDCXX} == "yes"
145 # Should probably move GMP, MPFR and MPC builds into the GCC >= 4.5
146 # specific build area, but we get better parallelism this way.
147 # We don't build compat versions of these.
148 . if !defined(MLIBDIR)
149 SUBDIR+= ../external/lgpl3/gmp/lib/libgmp
150 SUBDIR+= ../external/lgpl3/mpfr/lib/libmpfr
151 SUBDIR+= ../external/lgpl3/mpc/lib/libmpc
152 . endif # !defined(__MINIX) || ${MKLIBSTDCXX} == "yes"
153 . endif
154 .endif
157 # Libraries that depend upon any listed previously
158 # (and those that depend upon these [and ...])
160 #==================== 1st library dependency barrier ====================
161 SUBDIR+= .WAIT
163 .if ${MKDTRACE} != "no"
164 SUBDIR+= ../external/bsd/librtld_db/lib # depends on libutil
165 .endif
167 .if ${MKDTRACE} != "no" || ${MKCTF} != "no"
168 SUBDIR+= ../external/cddl/osnet/lib/libctf
169 .endif
171 SUBDIR+= ../external/public-domain/xz/lib # depends on libpthread
173 .if (${MKCRYPTO} != "no")
174 SUBDIR+= ../crypto/external/bsd/netpgp/libmj
175 SUBDIR+= ../crypto/external/bsd/netpgp/lib/verify # depends on libz
176 .endif
178 #SUBDIR+= ../external/bsd/libdwarf/lib # depends on libelf
179 SUBDIR+= ../external/mit/lua/lib # depends on libm
180 SUBDIR+= libcurses # depends on libterminfo
181 #SUBDIR+= libdm # depends on libprop
182 SUBDIR+= libedit # depends on libterminfo
183 SUBDIR+= libexecinfo # depends on libelf
184 #SUBDIR+= libppath # depends on libprop
185 #SUBDIR+= libperfuse # depends on libpuffs
186 #SUBDIR+= libquota # depends on libprop and librpcsvc
187 SUBDIR+= librefuse # depends on libpuffs
188 #SUBDIR+= libisns # depends on libpthread
189 .if (${MKRUMP} != "no")
190 SUBDIR+= librumpuser # depends on libpthread
191 SUBDIR+= librumphijack # depends on librumpclient and libpthread
192 .endif
194 .if (${MKNPF} != "no")
195 SUBDIR+= libnpf # depends on libprop
196 .endif
198 .if (${MKCRYPTO} != "no")
199 SUBDIR+= ../crypto/external/bsd/openssl/lib # depends on libcrypt
200 .endif
202 SUBDIR+= ../external/bsd/file/lib # depends on libz
204 .if (${MKISCSI} != "no")
205 SUBDIR+= ../external/bsd/iscsi/lib # depends on libpthread
206 .endif
208 .if (${MKZFS} != "no")
209 SUBDIR+= ../external/cddl/osnet/lib/libzfs
210 SUBDIR+= ../external/cddl/osnet/lib/libzpool
211 .endif
213 .if (${MKLVM} != "no")
214 SUBDIR+= ../external/gpl2/lvm2/lib # depends on libprop
215 .endif
217 .if (${MKBINUTILS} != "no")
218 SUBDIR+= ../external/gpl3/binutils/lib # libbfd depends on libz
219 .endif
221 .if (${MKLIBCXX} != "no")
222 SUBDIR+= ../external/bsd/libc++
223 .endif
225 .if (${MKGCC} != "no" && ${MKCXX} != "no" && ${MKLIBSTDCXX} != "no")
226 SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libstdc++-v3
227 SUBDIR+= ../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libsupc++
228 .endif
230 #==================== 2nd library dependency barrier ====================
231 SUBDIR+= .WAIT
233 SANITIZER_DIR=../external/gpl3/${EXTERNAL_GCC_SUBDIR}/lib/libasan
234 .if exists(${SANITIZER_DIR})
235 #SUBDIR+= ${SANITIZER_DIR}
236 .endif
238 SUBDIR+= ../external/bsd/libarchive/lib # depends on libxz
240 .if (${MKNPF} != "no")
241 SUBDIR+= npf # depends on libnpf
242 .endif
244 .if (${MKATF} != "no")
245 SUBDIR+= ../external/bsd/atf/lib # depends on libstdc++
246 .endif
248 .if (${MKKYUA} != "no")
249 SUBDIR+= ../external/bsd/lutok/lib # depends on lua and libstdc++
250 .endif
252 SUBDIR+= libform # depends on libcurses
253 SUBDIR+= libmenu # depends on libcurses
254 #SUBDIR+= libradius # depends on libcrypto if (${MKCRYPTO} != "no")
255 .if (${MKRUMP} != "no")
256 SUBDIR+= librump # depends on librumpuser
257 .endif
259 .if (${MKKERBEROS} != "no")
260 SUBDIR+= ../crypto/external/bsd/heimdal/lib # depends on libcrypto
261 # libedit, libterminfo,
262 .endif
264 .if (${MKCRYPTO} != "no")
265 #SUBDIR+= ../crypto/external/bsd/openssh/lib # depends on libcrypto, libz
266 SUBDIR+= ../crypto/external/bsd/netpgp/lib # depends on libcrypto, ...
267 .endif
269 SUBDIR+= ../external/bsd/libevent/lib # depends on libcrypto
270 .if ${MKDTRACE} != "no"
271 SUBDIR+= ../external/bsd/libproc/lib # depends on libstdc++, libctf
272 .endif
273 SUBDIR+= ../external/bsd/fetch/lib # depends on libssl
275 .if (${MKLDAP} != "no")
276 SUBDIR+= ../external/bsd/openldap/lib # depends on libcrypto, ...
277 .endif
279 #==================== 3rd library dependency barrier ====================
280 SUBDIR+= .WAIT
282 SUBDIR+= ../external/bsd/bind/lib # depends on heimdal, libcrypto
284 .if ${MKDTRACE} != "no"
285 SUBDIR+= ../external/cddl/osnet/lib/libdtrace # depends on libproc
286 .endif
288 .if (${MKRUMP} != "no")
289 SUBDIR+= librumpdev # depends on librump
290 SUBDIR+= librumpnet # depends on librump
291 SUBDIR+= librumpvfs # depends on librump
292 .endif
294 .if (${MKPAM} != "no")
295 SUBDIR+= libpam # depends on heimdal
296 .endif
298 .if (${MKCRYPTO} != "no")
299 SUBDIR+= ../crypto/external/bsd/libsaslc # depends on heimdal, openssl
300 .endif
302 SUBDIR+= ../external/bsd/mdocml/lib
304 .if (${MKRUMP} != "no")
305 #==================== 4th library dependency barrier ====================
306 SUBDIR+= .WAIT
308 SUBDIR+= libukfs # depends on librumpvfs, librump
310 .if (${MKTPM} != "no")
311 SUBDIR+= ../crypto/external/cpl/trousers/lib
312 .endif
314 #==================== 5th library dependency barrier ====================
315 SUBDIR+= .WAIT
317 SUBDIR+= libp2k # depends on libukfs, librumpvfs, libpuffs
319 .if (${MKTPM} != "no")
320 SUBDIR+= ../crypto/external/cpl/tpm-tools/lib # depends on trousers
321 .endif
323 .if !defined(BSD_MK_COMPAT_FILE)
324 SUBDIR+= ../sys/rump/dev/lib
325 SUBDIR+= ../sys/rump/fs/lib
326 SUBDIR+= ../sys/rump/kern/lib
327 SUBDIR+= ../sys/rump/net/lib
328 .endif
329 .endif
331 # Lua bindings come last, they might depend on anything
332 SUBDIR+= lua
334 # Needed by rump and rescue which are outside the smbfs tree
335 #SUBDIR+= ../external/bsd/smbfs/lib
337 .include <bsd.buildinstall.mk>
338 .include <bsd.subdir.mk>