xref: /freebsd/sys/modules/Makefile (revision c4f02a891fe62fe1277c89859922804ea2c27bcd)
1# $FreeBSD$
2
3.if !defined(NOCRYPT) || defined(ALL_MODULES)
4.if exists(${.CURDIR}/../opencrypto)
5_crypto=	crypto
6_cryptodev=	cryptodev
7.endif
8.if exists(${.CURDIR}/../crypto)
9_random=	random
10.endif
11.endif
12
13SUBDIR=	accf_data \
14	accf_http \
15	aha \
16	aic7xxx \
17	aio \
18	amr \
19	an \
20	ath \
21	aue \
22	axe \
23	bfe \
24	bge \
25	bridge \
26	cam \
27	cd9660 \
28	cd9660_iconv \
29	coda \
30	coda5 \
31	${_crypto} \
32	${_cryptodev} \
33	cue \
34	dc \
35	de \
36	digi \
37	dummynet \
38	en \
39	fatm \
40	fdc \
41	fdescfs \
42	firewire \
43	fxp \
44	geom \
45	gx \
46	harp \
47	hatm \
48	hifn \
49	if_disc \
50	if_ef \
51	if_faith \
52	if_gif \
53	if_gre \
54	if_ppp \
55	if_sl \
56	if_stf \
57	if_tap \
58	if_tun \
59	if_vlan \
60	ip6fw \
61	ip_mroute_mod \
62	ipfw \
63	isp \
64	ispfw \
65	joy \
66	kue \
67	lge \
68	libiconv \
69	libmbpool \
70	libmchain \
71	lpt \
72	mac_biba \
73	mac_bsdextended \
74	mac_ifoff \
75	mac_lomac \
76	mac_mls \
77	mac_none \
78	mac_partition \
79	mac_portacl \
80	mac_seeotheruids \
81	mac_stub \
82	mac_test \
83	mcd \
84	md \
85	mii \
86	mlx \
87	mpt \
88	msdosfs \
89	msdosfs_iconv \
90	my \
91	nfsclient \
92	nfsserver \
93	nge \
94	nmdm \
95	ntfs \
96	ntfs_iconv \
97	nullfs \
98	patm \
99	pcn \
100	plip \
101	portalfs \
102	ppbus \
103	ppi \
104	pps \
105	procfs \
106	pseudofs \
107	pst \
108	raidframe \
109	${_random} \
110	rc \
111	rc4 \
112	re \
113	rl \
114	rp \
115	rue \
116	sbsh \
117	scd \
118	sf \
119	sis \
120	sk \
121	sn \
122	snp \
123	ste \
124	sym \
125	sysvipc \
126	ti \
127	tl \
128	trm \
129	twe \
130	tx \
131	txp \
132	uart \
133	ubsa \
134	ubsec \
135	ucom \
136	udbp \
137	udf \
138	ufm \
139	uftdi \
140	ugen \
141	uhid \
142	ukbd \
143	ulpt \
144	umapfs \
145	umass \
146	umct \
147	umodem \
148	ums \
149	unionfs \
150	uplcom \
151	urio \
152	usb \
153	uscanner \
154	utopia \
155	uvisor \
156	uvscom \
157	vpo \
158	vr \
159	vx \
160	wb \
161	wlan \
162	xl
163
164.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "alpha"
165.if defined(WANT_EXT2FS_MODULE) || defined(ALL_MODULES)
166SUBDIR+=ext2fs
167.endif
168.endif
169
170.if !defined(NO_IPFILTER) || defined(ALL_MODULES)
171SUBDIR+=ipfilter
172.endif
173
174.if ${MACHINE_ARCH} != "sparc64"
175SUBDIR+=syscons
176.endif
177
178# XXX some of these can move to the general case when de-i386'ed
179# XXX some of these can move now, but are untested on other architectures.
180.if ${MACHINE_ARCH} == "i386"
181SUBDIR+=3dfx \
182	agp \
183	aic \
184	amd \
185	aout \
186	apm \
187	ar \
188	arcnet \
189	ath_hal \
190	awi \
191	bktr \
192	coff \
193	drm \
194	ed \
195	elink \
196	em \
197	ep \
198	fe \
199	hea \
200	hfa \
201	i2c \
202	ibcs2 \
203	ie \
204	linprocfs \
205	linux \
206	lnc \
207	ncp \
208	ncv \
209	netgraph \
210	nsp \
211	nwfs \
212	oltr \
213	pccard \
214	pcfclock \
215	pecoff \
216	ray \
217	safe \
218	sbni \
219	scsi_low \
220	smbfs \
221	sound \
222	speaker \
223	splash \
224	sppp \
225	sr \
226	stg \
227	streams \
228	vinum \
229	wi \
230	xe
231
232.if ${MACHINE} == "i386"
233SUBDIR+=aac \
234	acpi \
235	asr \
236	bios \
237	cardbus \
238	cbb \
239	ciss \
240	cm \
241	dpt \
242	el \
243	ex \
244	exca \
245	idt \
246	iir \
247	ips \
248	mly \
249	s3 \
250	vesa
251
252.elif ${MACHINE} == "pc98"
253SUBDIR+=canbepm \
254	canbus \
255	pmc \
256	snc
257.endif
258.endif
259
260.if ${MACHINE_ARCH} == "ia64"
261# Modules not enabled on ia64 (as compared to i386) include:
262#	aac acpi aout apm atspeaker drm ibcs2 linprocfs linux ncv
263#	nsp oltr pecoff s3 sbni stg vesa
264SUBDIR+=aic \
265	ar \
266	arcnet \
267	asr \
268	bktr \
269	cardbus \
270	cbb \
271	ciss \
272	cm \
273	coff \
274	el \
275	em \
276	ep \
277	exca \
278	fe \
279	hea \
280	hfa \
281	iir \
282	mly \
283	netgraph \
284	pccard \
285	ray \
286	rc \
287	scsi_low \
288	smbfs \
289	sound \
290	splash \
291	sppp \
292	sr \
293	streams \
294	vinum \
295	wi \
296	xe
297.endif
298
299.if ${MACHINE_ARCH} == "alpha"
300SUBDIR+=agp \
301	linprocfs \
302	linux \
303	osf1 \
304	sound \
305	sppp \
306	vinum
307.endif
308
309.if ${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "sparc64"
310SUBDIR+=gem
311.endif
312
313.if ${MACHINE_ARCH} == "sparc64"
314SUBDIR+=hme
315.endif
316
317.if defined(ALL_MODULES)
318SUBDIR+=null
319SUBDIR+=ufs
320.endif
321
322.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
323SUBDIR=${MODULES_OVERRIDE}
324.endif
325
326# Calling kldxref(8) for each module is expensive.
327.if !defined(NO_XREF)
328.MAKEFLAGS+=	-DNO_XREF
329afterinstall:
330	@if type kldxref >/dev/null 2>&1; then \
331		${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
332		kldxref ${DESTDIR}${KMODDIR}; \
333	fi
334.endif
335
336.include <bsd.subdir.mk>
337