xref: /freebsd/sys/modules/Makefile (revision 9b1f97079c5255ef7ea87fa302faccaf93b4bd2a)
1# $FreeBSD$
2
3.include <bsd.own.mk>
4
5SUBDIR=	${_3dfx} \
6	${_3dfx_linux} \
7	${_aac} \
8	accf_data \
9	accf_dns \
10	accf_http \
11	${_acpi} \
12	ae \
13	${_aesni} \
14	age \
15	${_agp} \
16	aha \
17	${_ahb} \
18	ahci \
19	${_aic} \
20	aic7xxx \
21	aio \
22	alc \
23	ale \
24	alq \
25	${_amd} \
26	${_amdsbwd} \
27	${_amdtemp} \
28	amr \
29	${_an} \
30	${_aout} \
31	${_apm} \
32	${_arcmsr} \
33	${_arcnet} \
34	${_asmc} \
35	${_asr} \
36	ata \
37	ath \
38	${_auxio} \
39	bce \
40	bfe \
41	bge \
42	${_bios} \
43	${_bktr} \
44	${_bm} \
45	bridgestp \
46	bwi \
47	bwn \
48	cam \
49	${_canbepm} \
50	${_canbus} \
51	${_cardbus} \
52	cas \
53	${_cbb} \
54	cd9660 \
55	cd9660_iconv \
56	${_ce} \
57	${_ciss} \
58	${_cm} \
59	${_cmx} \
60	coda \
61	coda5 \
62	${_coff} \
63	${_coretemp} \
64	${_cp} \
65	${_cpuctl} \
66	${_cpufreq} \
67	${_crypto} \
68	${_cryptodev} \
69	${_cs} \
70	${_ctau} \
71	${_cxgb} \
72	${_cyclic} \
73	dc \
74	dcons \
75	dcons_crom \
76	de \
77	${_dpms} \
78	${_dpt} \
79	${_drm} \
80	${_dtrace} \
81	dummynet \
82	${_ed} \
83	${_elink} \
84	${_em} \
85	en \
86	${_ep} \
87	${_epic} \
88	${_et} \
89	${_ex} \
90	${_exca} \
91	${_ext2fs} \
92	fatm \
93	fdc \
94	fdescfs \
95	${_fe} \
96	firewire \
97	firmware \
98	fxp \
99	gem \
100	geom \
101	${_glxsb} \
102	hatm \
103	hifn \
104	hme \
105	${_hptiop} \
106	${_hptmv} \
107	${_hptrr} \
108	hwpmc \
109	${_i2c} \
110	${_ibcs2} \
111	${_ichwd} \
112	${_ida} \
113	${_ie} \
114	if_bridge \
115	if_carp \
116	if_disc \
117	if_edsc \
118	if_ef \
119	if_epair \
120	if_faith \
121	if_gif \
122	if_gre \
123	if_lagg \
124	${_if_ndis} \
125	if_stf \
126	if_tap \
127	if_tun \
128	if_vlan \
129	${_igb} \
130	${_iir} \
131	${_io} \
132	ipdivert \
133	${_ipfilter} \
134	ipfw \
135	ipfw_nat \
136	${_ipmi} \
137	ip_mroute_mod \
138	${_ips} \
139	${_ipw} \
140	${_ipwfw} \
141	iscsi \
142	isp \
143	ispfw \
144	${_iwi} \
145	${_iwifw} \
146	${_iwn} \
147	${_iwnfw} \
148	${_ixgb} \
149	${_ixgbe} \
150	jme \
151	joy \
152	kbdmux \
153	krpc \
154	ksyms \
155	le \
156	lge \
157	libalias \
158	libiconv \
159	libmbpool \
160	libmchain \
161	${_lindev} \
162	${_linprocfs} \
163	${_linsysfs} \
164	${_linux} \
165	lmc \
166	lpt \
167	mac_biba \
168	mac_bsdextended \
169	mac_ifoff \
170	mac_lomac \
171	mac_mls \
172	mac_none \
173	mac_partition \
174	mac_portacl \
175	mac_seeotheruids \
176	mac_stub \
177	mac_test \
178	malo \
179	mcd \
180	md \
181	mem \
182	mfi \
183	mii \
184	mlx \
185	${_mly} \
186	mmc \
187	mmcsd \
188	mpt \
189	mqueue \
190	msdosfs \
191	msdosfs_iconv \
192	${_mse} \
193	msk \
194	mvs \
195	mwl \
196	mwlfw \
197	mxge \
198	my \
199	${_ncp} \
200	${_ncv} \
201	${_ndis} \
202	${_netgraph} \
203	${_nfe} \
204	nfs_common \
205	nfscl \
206	nfsclient \
207	nfscommon \
208	nfsd \
209	nfslock \
210	nfslockd \
211	nfsserver \
212	nfssvc \
213	nge \
214	nmdm \
215	${_nsp} \
216	ntfs \
217	ntfs_iconv \
218	nullfs \
219	${_nve} \
220	${_nvram} \
221	${_nwfs} \
222	${_nxge} \
223	${_opensolaris} \
224	${_padlock} \
225	patm \
226	${_pccard} \
227	${_pcfclock} \
228	pcn \
229	${_pf} \
230	${_pflog} \
231	plip \
232	${_pmc} \
233	portalfs \
234	ppbus \
235	ppc \
236	ppi \
237	pps \
238	procfs \
239	pseudofs \
240	${_pst} \
241	pty  \
242	puc \
243	ral \
244	ralfw \
245	${_random} \
246	rc4 \
247	${_rdma} \
248	re \
249	reiserfs \
250	rl \
251	runfw \
252	${_s3} \
253	${_safe} \
254	${_sbni} \
255	scc \
256	scd \
257	${_scsi_low} \
258	sdhci \
259	sem \
260	sf \
261	sge \
262	siba_bwn \
263	siftr \
264	siis \
265	sis \
266	sk \
267	${_smbfs} \
268	sn \
269	${_snc} \
270	snp \
271	${_sound} \
272	${_speaker} \
273	${_splash} \
274	${_sppp} \
275	ste \
276	${_stg} \
277	stge \
278	${_streams} \
279	${_svr4} \
280	${_sym} \
281	${_syscons} \
282	sysvipc \
283	ti \
284	tl \
285	tmpfs \
286	${_tpm} \
287	trm \
288	${_twa} \
289	twe \
290	tx \
291	txp \
292	uart \
293	ubsec \
294	udf \
295	udf_iconv \
296	ufs \
297	unionfs \
298	usb \
299	utopia \
300	${_vesa} \
301	vge \
302	vkbd \
303	${_vpo} \
304	vr \
305	vx \
306	wb \
307	${_wi} \
308	wlan \
309	wlan_acl \
310	wlan_amrr \
311	wlan_ccmp \
312	wlan_rssadapt \
313	wlan_tkip \
314	wlan_wep \
315	wlan_xauth \
316	${_wpi} \
317	${_wpifw} \
318	${_x86bios} \
319	${_xe} \
320	xfs \
321	xl \
322	${_zfs} \
323	zlib \
324
325.if ${MACHINE_CPUARCH} != "powerpc" && ${MACHINE_ARCH} != "arm" && \
326	${MACHINE_ARCH} != "mips"
327_syscons=	syscons
328_vpo=		vpo
329.endif
330
331.if ${MACHINE_ARCH} != "arm" && ${MACHINE_ARCH} != "mips"
332# no BUS_SPACE_UNSPECIFIED
333# No barrier instruction support (specific to this driver)
334_sym=		sym
335# intr_disable() is a macro, causes problems
336_cxgb=		cxgb
337.endif
338
339.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
340.if exists(${.CURDIR}/../opencrypto)
341_crypto=	crypto
342_cryptodev=	cryptodev
343.endif
344.if exists(${.CURDIR}/../crypto)
345_random=	random
346.endif
347.endif
348
349.if ${MK_IPFILTER} != "no" || defined(ALL_MODULES)
350_ipfilter=	ipfilter
351.endif
352
353.if ${MK_NETGRAPH} != "no" || defined(ALL_MODULES)
354_netgraph=	netgraph
355.endif
356
357.if ${MK_PF} != "no" || defined(ALL_MODULES)
358_pf=		pf
359_pflog=		pflog
360.endif
361
362.if ${MACHINE_ARCH} == "i386"
363# XXX some of these can move to the general case when de-i386'ed
364# XXX some of these can move now, but are untested on other architectures.
365_3dfx=		3dfx
366_3dfx_linux=	3dfx_linux
367_agp=		agp
368_aic=		aic
369_amd=		amd
370_an=		an
371_aout=		aout
372_apm=		apm
373_arcnet=	arcnet
374_bktr=		bktr
375_cardbus=	cardbus
376_cbb=		cbb
377_ce=		ce
378_coff=		coff
379_cp=		cp
380_cpuctl=	cpuctl
381_cpufreq=	cpufreq
382_cs=		cs
383.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
384_cyclic=	cyclic
385.endif
386_dpms=		dpms
387_drm=		drm
388.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
389_dtrace=	dtrace
390.endif
391_ed=		ed
392_elink=		elink
393_em=		em
394_ep=		ep
395_et=		et
396_exca=		exca
397_ext2fs=	ext2fs
398_fe=		fe
399_glxsb=		glxsb
400_i2c=		i2c
401_ibcs2=		ibcs2
402_ie=		ie
403_if_ndis=	if_ndis
404_igb=		igb
405_io=		io
406_lindev=	lindev
407_linprocfs=	linprocfs
408_linsysfs=	linsysfs
409_linux=		linux
410_mse=		mse
411.if ${MK_NCP} != "no"
412_ncp=		ncp
413.endif
414_ncv=		ncv
415_ndis=		ndis
416_nsp=		nsp
417.if ${MK_NCP} != "no"
418_nwfs=		nwfs
419.endif
420.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
421_opensolaris=	opensolaris
422.endif
423_pccard=	pccard
424_pcfclock=	pcfclock
425_pst=		pst
426_rdma=		rdma
427_safe=		safe
428_sbni=		sbni
429_scsi_low=	scsi_low
430_smbfs=		smbfs
431_sound=		sound
432_speaker=	speaker
433_splash=	splash
434_sppp=		sppp
435_stg=		stg
436_streams=	streams
437_svr4=		svr4
438_wi=		wi
439_xe=		xe
440.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
441_zfs=		zfs
442.endif
443.if ${MACHINE} == "i386"
444_aac=		aac
445_acpi=		acpi
446.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
447_aesni=		aesni
448.endif
449_ahb=		ahb
450_amdsbwd=	amdsbwd
451_amdtemp=	amdtemp
452_arcmsr=	arcmsr
453_asmc=		asmc
454_asr=		asr
455_bios=		bios
456_ciss=		ciss
457_cm=		cm
458_cmx=		cmx
459_coretemp=	coretemp
460_ctau=		ctau
461_dpt=		dpt
462_ex=		ex
463_hptiop=	hptiop
464_hptmv=		hptmv
465_hptrr=		hptrr
466_ichwd=		ichwd
467_ida=		ida
468_iir=		iir
469_ipmi=		ipmi
470_ips=		ips
471_ipw=		ipw
472_ipwfw=		ipwfw
473_iwi=		iwi
474_iwifw=		iwifw
475_iwn=		iwn
476_iwnfw=		iwnfw
477_ixgb=		ixgb
478_ixgbe=		ixgbe
479_mly=		mly
480_nfe=		nfe
481_nve=		nve
482_nvram=		nvram
483_nxge=		nxge
484_tpm=		tpm
485_wpi=		wpi
486_wpifw=		wpifw
487.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
488_padlock=	padlock
489.endif
490_s3=		s3
491_twa=		twa
492_vesa=		vesa
493_x86bios=	x86bios
494.elif ${MACHINE} == "pc98"
495_canbepm=	canbepm
496_canbus=	canbus
497_pmc=		pmc
498_snc=		snc
499.endif
500.endif
501
502.if ${MACHINE_ARCH} == "amd64"
503_aac=		aac
504_acpi=		acpi
505.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
506_aesni=		aesni
507.endif
508_agp=		agp
509_an=		an
510_amdsbwd=	amdsbwd
511_amdtemp=	amdtemp
512_arcmsr=	arcmsr
513_asmc=		asmc
514_cardbus=	cardbus
515_cbb=		cbb
516_cmx=		cmx
517_ciss=		ciss
518_coretemp=	coretemp
519_cpuctl=	cpuctl
520_cpufreq=	cpufreq
521.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
522_cyclic=	cyclic
523.endif
524_dpms=		dpms
525_drm=		drm
526.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
527_dtrace=	dtrace
528.endif
529_ed=		ed
530_et=		et
531_em=		em
532_exca=		exca
533_ext2fs=	ext2fs
534_hptiop=	hptiop
535_hptmv=		hptmv
536_hptrr=		hptrr
537_i2c=		i2c
538_ichwd=		ichwd
539_ida=		ida
540_if_ndis=	if_ndis
541_igb=		igb
542_iir=		iir
543_io=		io
544_ipmi=		ipmi
545_ips=		ips
546_ipw=		ipw
547_ipwfw=		ipwfw
548_iwi=		iwi
549_iwifw=		iwifw
550_iwn=		iwn
551_iwnfw=		iwnfw
552_ixgb=		ixgb
553_ixgbe=		ixgbe
554_lindev=	lindev
555_linprocfs=	linprocfs
556_linsysfs=	linsysfs
557_linux=		linux
558_mly=		mly
559_ndis=		ndis
560_nfe=		nfe
561_nve=		nve
562_nvram=		nvram
563_nxge=		nxge
564.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
565_opensolaris=	opensolaris
566.endif
567.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
568_padlock=	padlock
569.endif
570_pccard=	pccard
571_rdma=		rdma
572_s3=		s3
573_safe=		safe
574_scsi_low=	scsi_low
575_smbfs=		smbfs
576_sound=		sound
577_speaker=	speaker
578_splash=	splash
579_sppp=		sppp
580_tpm=		tpm
581_twa=		twa
582_vesa=		vesa
583_x86bios=	x86bios
584_wi=		wi
585_wpi=		wpi
586_wpifw=		wpifw
587.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
588_zfs=		zfs
589.endif
590.endif
591
592.if ${MACHINE_ARCH} == "ia64"
593_aac=		aac
594_aic=		aic
595_an=		an
596_arcnet=	arcnet
597_asr=		asr
598_bktr=		bktr
599_cardbus=	cardbus
600_cbb=		cbb
601_ciss=		ciss
602_cm=		cm
603_cmx=		cmx
604_coff=		coff
605_cpufreq=	cpufreq
606_dpt=		dpt
607_em=		em
608_ep=		ep
609_et=		et
610_exca=		exca
611_fe=		fe
612_hptiop=	hptiop
613_ida=		ida
614_igb=		igb
615_iir=		iir
616_ips=		ips
617_mly=		mly
618_pccard=	pccard
619_scsi_low=	scsi_low
620_smbfs=		smbfs
621_sound=		sound
622_splash=	splash
623_sppp=		sppp
624_streams=	streams
625_tpm=		tpm
626_twa=		twa
627_wi=		wi
628_xe=		xe
629.endif
630
631.if ${MACHINE_CPUARCH} == "powerpc"
632_an=		an
633_bm=		bm
634_cpufreq=	cpufreq
635_nvram=		powermac_nvram
636_smbfs=		smbfs
637_sound=		sound
638.endif
639
640.if ${MACHINE_ARCH} == "powerpc64"
641.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
642_opensolaris=	opensolaris
643.endif
644.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
645_zfs=		zfs
646.endif
647.endif
648
649.if ${MACHINE_ARCH} == "sparc64"
650_auxio=		auxio
651_em=		em
652_epic=		epic
653_i2c=		i2c
654_igb=		igb
655.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
656_opensolaris=	opensolaris
657.endif
658_smbfs=		smbfs
659_sound=		sound
660.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
661_zfs=		zfs
662.endif
663.endif
664
665.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
666SUBDIR=${MODULES_OVERRIDE}
667.endif
668
669.for reject in ${WITHOUT_MODULES}
670SUBDIR:= ${SUBDIR:N${reject}}
671.endfor
672
673# Calling kldxref(8) for each module is expensive.
674.if !defined(NO_XREF)
675.MAKEFLAGS+=	-DNO_XREF
676afterinstall:
677	@if type kldxref >/dev/null 2>&1; then \
678		${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
679		kldxref ${DESTDIR}${KMODDIR}; \
680	fi
681.endif
682
683.include <bsd.subdir.mk>
684