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