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