xref: /netbsd/lib/Makefile (revision 236f39c1)
1#	$NetBSD: Makefile,v 1.183 2012/05/26 22:03:04 christos Exp $
2#	from: @(#)Makefile	5.25.1.1 (Berkeley) 5/7/91
3
4.include <bsd.own.mk>
5
6SUBDIR=		csu
7
8.if (${MKGCC} != "no")
9. if ${HAVE_GCC} == 4
10.  if (${USE_COMPILERCRTSTUFF} == "yes")
11SUBDIR+=	../gnu/lib/crtstuff4
12.  endif
13SUBDIR+=	../gnu/lib/libgcc4
14. else
15.  if (${USE_COMPILERCRTSTUFF} == "yes")
16SUBDIR+=	../external/gpl3/gcc/lib/crtstuff
17.  endif
18SUBDIR+=	../external/gpl3/gcc/lib/libgcc
19. endif
20.endif
21
22SUBDIR+=	libc
23SUBDIR+=	.WAIT
24
25#
26# The SUBDIRs above are included here for completeness but should be built
27# and installed prior to make(dependall) in this file, as libraries listed
28# below will depend on versions from DESTDIR only.
29#
30
31SUBDIR+=	i18n_module
32
33SUBDIR+=	libarch \
34		libbluetooth libbsdmalloc libbz2 \
35		libcompat libcrypt libexecinfo \
36		libintl libipsec libisns libkvm libm \
37		libossaudio libpci libpmc libposix libprop libpthread \
38		libpthread_dbg libpuffs libresolv librmt librpcsvc librt \
39		librumpclient libtelnet libterminfo \
40		libusbhid libutil libwrap liby libz
41
42.if (${MKSKEY} != "no")
43SUBDIR+=	libskey
44.endif
45
46.if (${MKCRYPTO} != "no")
47SUBDIR+=	../crypto/external/bsd/netpgp/libmj
48.endif
49
50.if (${MKMDNS} != "no")
51SUBDIR+=	../external/apache2/mDNSResponder/lib
52.endif
53
54SUBDIR+=	../external/bsd/am-utils/lib
55
56.if (${MKATF} != "no")
57SUBDIR+=	../external/bsd/atf/lib
58.endif
59
60SUBDIR+=	../external/bsd/flex/lib
61SUBDIR+=	../external/bsd/tre/lib
62SUBDIR+=	../external/bsd/libdwarf/lib
63SUBDIR+=	../external/bsd/libelf/lib
64SUBDIR+=	../external/bsd/libevent/lib
65SUBDIR+=	../external/bsd/liblzf/lib
66SUBDIR+=	../external/bsd/libpcap/lib
67
68SUBDIR+=	../external/mit/lua/lib
69SUBDIR+=	../external/mit/expat/lib
70
71SUBDIR+=	../external/public-domain/sqlite/lib
72SUBDIR+=	../external/public-domain/xz/lib
73
74SUBDIR+=	../gnu/lib/libmalloc
75
76.if (${MKGCC} != "no")
77. if ${HAVE_GCC} == 4
78SUBDIR+=	../gnu/lib/libobjc4
79. else
80SUBDIR+=	../external/gpl3/gcc/lib/libobjc
81SUBDIR+=	../external/gpl3/gcc/lib/libgomp
82. endif
83. if ${HAVE_GCC} >= 45 && !defined(MLIBDIR)
84# Should probably move GMP, MPFR and MPC builds into the GCC >= 4.5
85# specific build area, but we get better parallelism this way.
86SUBDIR+=	../external/lgpl3/gmp/lib/libgmp
87SUBDIR+=	../external/lgpl3/mpfr/lib/libmpfr
88SUBDIR+=	../external/lgpl2/mpc/lib/libmpc
89. endif
90.endif
91
92#
93# Libraries that depend upon any listed previously
94# (and those that depend upon these [and ...])
95#
96#==================== 1st library dependency barrier ====================
97SUBDIR+=	.WAIT
98
99SUBDIR+=	libcurses	# depends on libterminfo
100SUBDIR+=	libdm		# depends on libprop
101SUBDIR+=	libedit		# depends on libterminfo
102SUBDIR+=	libppath	# depends on libprop
103SUBDIR+=	libperfuse	# depends on libpuffs
104SUBDIR+=	libquota	# depends on libprop and librpcsvc
105SUBDIR+=	librefuse	# depends on libpuffs
106SUBDIR+=	librumpuser	# depends on libpthread
107SUBDIR+=	librumphijack	# depends on librumpclient and libpthread
108
109.if (${MKNPF} != "no")
110SUBDIR+=	libnpf		# depends on libprop
111.endif
112
113.if (${MKCRYPTO} != "no")
114SUBDIR+=	../crypto/external/bsd/openssl/lib # depends on libcrypt
115.endif
116
117SUBDIR+=	../external/bsd/file/lib	# depends on libz
118
119.if (${MKISCSI} != "no")
120SUBDIR+=	../external/bsd/iscsi/lib	# depends on libpthread
121.endif
122
123SUBDIR+=	../external/bsd/libarchive/lib	# depends on libxz
124
125.if (${MKLVM} != "no")
126SUBDIR+=	../external/gpl2/lvm2/lib	# depends on libprop
127.endif
128
129.if (${MKBINUTILS} != "no")
130SUBDIR+=	../external/gpl3/binutils/lib	# libbfd depends on libz
131.endif
132
133.if (${MKGCC} != "no" && ${MKCXX} != "no")
134. if ${HAVE_GCC} == 4
135SUBDIR+=	../gnu/lib/libstdc++-v3_4	# depends on libm
136SUBDIR+=	../gnu/lib/libsupc++4
137. else
138SUBDIR+=	../external/gpl3/gcc/lib/libstdc++-v3
139SUBDIR+=	../external/gpl3/gcc/lib/libsupc++
140. endif
141.endif
142
143#==================== 2nd library dependency barrier ====================
144SUBDIR+=	.WAIT
145
146SUBDIR+=	libform		# depends on libcurses
147SUBDIR+=	libmenu		# depends on libcurses
148SUBDIR+=	libradius	# depends on libcrypto if (${MKCRYPTO} != "no")
149SUBDIR+=	librump		# depends on librumpuser
150
151.if (${MKKERBEROS} != "no")
152SUBDIR+=	../crypto/external/bsd/heimdal/lib	# depends on libcrypto
153							# libedit, libterminfo,
154.endif
155
156.if (${MKCRYPTO} != "no")
157SUBDIR+=	../crypto/external/bsd/openssh/lib # depends on libcrypto, libz
158SUBDIR+=	../crypto/external/bsd/netpgp/lib  # depends on libcrypto, ...
159.endif
160
161SUBDIR+=	../external/bsd/bind/lib	# depends on libcrypto
162SUBDIR+=	../external/bsd/fetch/lib	# depends on libssl
163
164.if (${MKLDAP} != "no")
165SUBDIR+=	../external/bsd/openldap/lib	# depends on libcrypto, ...
166.endif
167
168#==================== 3rd library dependency barrier ====================
169SUBDIR+=	.WAIT
170
171SUBDIR+=	librumpdev	# depends on librump
172SUBDIR+=	librumpnet	# depends on librump
173SUBDIR+=	librumpvfs	# depends on librump
174
175.if (${MKPAM} != "no")
176SUBDIR+=	libpam		# depends on heimdal
177.endif
178
179.if (${MKCRYPTO} != "no")
180SUBDIR+=	../crypto/external/bsd/libsaslc	# depends on heimdal, openssl
181.endif
182
183SUBDIR+=	../external/bsd/mdocml/lib
184
185#==================== 4th library dependency barrier ====================
186SUBDIR+=	.WAIT
187
188SUBDIR+=	libukfs		# depends on librumpvfs, librump
189
190#==================== 5th library dependency barrier ====================
191SUBDIR+=	.WAIT
192
193SUBDIR+=	libp2k		# depends on libukfs, librumpvfs, libpuffs
194
195# Lua bindings come last, they might depend on anything
196SUBDIR+=	lua
197
198.include <bsd.subdir.mk>
199