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