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