xref: /freebsd/sys/modules/Makefile (revision 721351876cd4d3a8a700f62d2061331fa951a488)
1# $FreeBSD$
2
3.include <bsd.own.mk>
4
5SUBDIR=	${_3dfx} \
6	${_3dfx_linux} \
7	${_aac} \
8	accf_data \
9	accf_http \
10	${_acpi} \
11	age \
12	${_agp} \
13	aha \
14	${_ahb} \
15	${_aic} \
16	aic7xxx \
17	aio \
18	${_amd} \
19	amr \
20	${_an} \
21	${_aout} \
22	${_apm} \
23	${_ar} \
24	${_arcmsr} \
25	${_arcnet} \
26	${_arl} \
27	${_asmc} \
28	${_asr} \
29	ata \
30	${_ath} \
31	${_ath_hal} \
32	${_ath_rate_amrr} \
33	${_ath_rate_onoe} \
34	${_ath_rate_sample} \
35	aue \
36	${_auxio} \
37	axe \
38	bce \
39	bfe \
40	bge \
41	${_bios} \
42	${_bktr} \
43	${_bm} \
44	bridgestp \
45	cam \
46	${_canbepm} \
47	${_canbus} \
48	${_cardbus} \
49	${_cbb} \
50	cd9660 \
51	cd9660_iconv \
52	cdce \
53	${_ce} \
54	${_ciss} \
55	${_cm} \
56	${_cmx} \
57	${_cnw} \
58	coda \
59	coda5 \
60	${_coff} \
61	${_coretemp} \
62	${_cp} \
63	${_cpufreq} \
64	${_crypto} \
65	${_cryptodev} \
66	${_cs} \
67	${_ctau} \
68	cue \
69	${_cx} \
70	cxgb \
71	${_cyclic} \
72	dc \
73	dcons \
74	dcons_crom \
75	de \
76	${_digi} \
77	${_dpt} \
78	${_drm} \
79	${_dtrace} \
80	dummynet \
81	${_ed} \
82	${_elink} \
83	${_em} \
84	en \
85	${_ep} \
86	${_et} \
87	${_ex} \
88	${_exca} \
89	${_ext2fs} \
90	fatm \
91	fdc \
92	fdescfs \
93	${_fe} \
94	firewire \
95	firmware \
96	fxp \
97	gem \
98	geom \
99	hatm \
100	hifn \
101	hme \
102	${_hptiop} \
103	${_hptmv} \
104	${_hptrr} \
105	hwpmc \
106	${_i2c} \
107	${_ibcs2} \
108	${_ichwd} \
109	${_ida} \
110	${_ie} \
111	if_bridge \
112	if_disc \
113	if_edsc \
114	if_ef \
115	if_faith \
116	if_gif \
117	if_gre \
118	if_lagg \
119	${_if_ndis} \
120	if_ppp \
121	if_sl \
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	mpt \
183	mqueue \
184	msdosfs \
185	msdosfs_iconv \
186	${_mse} \
187	msk \
188	mxge \
189	my \
190	${_ncp} \
191	${_ncv} \
192	${_ndis} \
193	netgraph \
194	${_nfe} \
195	nfsclient \
196	nfslockd \
197	nfsserver \
198	nge \
199	nmdm \
200	${_nsp} \
201	ntfs \
202	ntfs_iconv \
203	nullfs \
204	${_nve} \
205	${_nvram} \
206	${_nwfs} \
207	${_nxge} \
208	${_oltr} \
209	${_opensolaris} \
210	${_padlock} \
211	patm \
212	${_pccard} \
213	${_pcfclock} \
214	pcn \
215	${_pf} \
216	${_pflog} \
217	plip \
218	${_pmc} \
219	portalfs \
220	ppbus \
221	ppc \
222	ppi \
223	pps \
224	procfs \
225	pseudofs \
226	${_pst} \
227	puc \
228	ral \
229	${_random} \
230	${_ray} \
231	rc \
232	rc4 \
233	${_rdma} \
234	re \
235	reiserfs \
236	rl \
237	rp \
238	rue \
239	rum \
240	${_s3} \
241	${_safe} \
242	${_sbni} \
243	sbsh \
244	scc \
245	scd \
246	${_scsi_low} \
247	sem \
248	sf \
249	${_sio} \
250	sis \
251	sk \
252	${_smbfs} \
253	sn \
254	${_snc} \
255	snp \
256	${_sound} \
257	${_speaker} \
258	${_splash} \
259	${_sppp} \
260	${_sr} \
261	ste \
262	${_stg} \
263	stge \
264	${_streams} \
265	sym \
266	${_syscons} \
267	sysvipc \
268	ti \
269	tl \
270	${_tmpfs} \
271	trm \
272	${_twa} \
273	twe \
274	tx \
275	txp \
276	uark \
277	uart \
278	ubsa \
279	ubsec \
280	ubser \
281	ucom \
282	ucycom \
283	udav \
284	udbp \
285	udf \
286	udf_iconv \
287	ufm \
288	${_ufs} \
289	ufoma \
290	uftdi \
291	ugen \
292	uhid \
293	ukbd \
294	ulpt \
295	umass \
296	umct \
297	umodem \
298	ums \
299	unionfs \
300	uplcom \
301	ural \
302	urio \
303	usb \
304	uscanner \
305	uslcom \
306	utopia \
307	uvisor \
308	uvscom \
309	${_vesa} \
310	vge \
311	vkbd \
312	${_vpo} \
313	vr \
314	vx \
315	wb \
316	${_wi} \
317	wlan \
318	wlan_acl \
319	wlan_amrr \
320	wlan_ccmp \
321	wlan_rssadapt \
322	wlan_tkip \
323	wlan_wep \
324	wlan_xauth \
325	${_wpi} \
326	${_wpifw} \
327	${_xe} \
328	xfs \
329	xl \
330	${_zfs} \
331	zlib \
332	zyd
333
334.if ${MACHINE_ARCH} != "powerpc"
335_syscons=	syscons
336_vpo=		vpo
337.endif
338
339.if defined(ALL_MODULES)
340_ufs=		ufs
341.endif
342
343.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
344.if exists(${.CURDIR}/../opencrypto)
345_crypto=	crypto
346_cryptodev=	cryptodev
347.endif
348.if exists(${.CURDIR}/../crypto)
349_random=	random
350.endif
351.endif
352
353.if ${MK_IPFILTER} != "no" || defined(ALL_MODULES)
354_ipfilter=	ipfilter
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_ar=		ar
374_arcnet=	arcnet
375_ath=		ath
376_ath_hal=	ath_hal
377_ath_rate_amrr=	ath_rate_amrr
378_ath_rate_onoe=	ath_rate_onoe
379_ath_rate_sample=ath_rate_sample
380_bktr=		bktr
381_cardbus=	cardbus
382_cbb=		cbb
383_ce=		ce
384_coff=		coff
385_cp=		cp
386_cpufreq=	cpufreq
387_cs=		cs
388.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
389_cyclic=	cyclic
390.endif
391_digi=		digi
392_drm=		drm
393.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
394_dtrace=	dtrace
395.endif
396_ed=		ed
397_elink=		elink
398_em=		em
399_ep=		ep
400_et=		et
401_exca=		exca
402_ext2fs=	ext2fs
403_fe=		fe
404_i2c=		i2c
405_ibcs2=		ibcs2
406_ie=		ie
407_if_ndis=	if_ndis
408_igb=		igb
409_io=		io
410_linprocfs=	linprocfs
411_linsysfs=	linsysfs
412_linux=		linux
413_mse=		mse
414.if ${MK_NCP} != "no"
415_ncp=		ncp
416.endif
417_ncv=		ncv
418_ndis=		ndis
419_nsp=		nsp
420.if ${MK_NCP} != "no"
421_nwfs=		nwfs
422.endif
423_oltr=		oltr
424.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
425_opensolaris=	opensolaris
426.endif
427_pccard=	pccard
428_pcfclock=	pcfclock
429_pst=		pst
430_ray=		ray
431_rdma=		rdma
432_safe=		safe
433_sbni=		sbni
434_scsi_low=	scsi_low
435_sio=		sio
436_smbfs=		smbfs
437_sound=		sound
438_speaker=	speaker
439_splash=	splash
440_sppp=		sppp
441_sr=		sr
442_stg=		stg
443_streams=	streams
444_tmpfs=		tmpfs
445_wi=		wi
446_xe=		xe
447.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
448_zfs=		zfs
449.endif
450.if ${MACHINE} == "i386"
451_aac=		aac
452_acpi=		acpi
453_ahb=		ahb
454_arcmsr=	arcmsr
455_arl=		arl
456_asmc=		asmc
457_asr=		asr
458_bios=		bios
459_ciss=		ciss
460_cm=		cm
461_cmx=		cmx
462_cnw=		cnw
463_coretemp=	coretemp
464_ctau=		ctau
465_cx=		cx
466_dpt=		dpt
467_ex=		ex
468_hptiop=	hptiop
469_hptmv=		hptmv
470_hptrr=		hptrr
471_ichwd=		ichwd
472_ida=		ida
473_iir=		iir
474_ipmi=		ipmi
475_ips=		ips
476_ipw=		ipw
477_ipwfw=		ipwfw
478_iwi=		iwi
479_iwifw=		iwifw
480_iwn=		iwn
481_iwnfw=		iwnfw
482_ixgb=		ixgb
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_cpufreq=	cpufreq
524.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
525_cyclic=	cyclic
526.endif
527_digi=		digi
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_wi=		wi
578_wpi=		wpi
579_wpifw=		wpifw
580.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
581_zfs=		zfs
582.endif
583.endif
584
585.if ${MACHINE_ARCH} == "ia64"
586# Modules not enabled on ia64 (as compared to i386) include:
587#	aac acpi aout apm atspeaker drm ibcs2 linprocfs linux ncv
588#	nsp oltr s3 sbni stg vesa
589# acpi is not enabled because it is broken as a module on ia64
590_aic=		aic
591#_ar=		ar	not 64-bit clean
592_an=		an
593_arcnet=	arcnet
594_asr=		asr
595_bktr=		bktr
596_cardbus=	cardbus
597_cbb=		cbb
598_ciss=		ciss
599_cm=		cm
600_cmx=		cmx
601_coff=		coff
602_cpufreq=	cpufreq
603_em=		em
604_ep=		ep
605_exca=		exca
606_fe=		fe
607_igb=		igb
608_iir=		iir
609_mly=		mly
610_pccard=	pccard
611_scsi_low=	scsi_low
612_smbfs=		smbfs
613_sound=		sound
614_splash=	splash
615_sppp=		sppp
616#_sr=		sr		not 64bit clean
617_streams=	streams
618_wi=		wi
619_xe=		xe
620.endif
621
622.if ${MACHINE_ARCH} == "powerpc"
623_an=		an
624_ath=		ath
625_ath_hal=	ath_hal
626_ath_rate_amrr=	ath_rate_amrr
627_ath_rate_onoe=	ath_rate_onoe
628_ath_rate_sample=ath_rate_sample
629_bm=		bm
630_nvram=		powermac_nvram
631_smbfs=		smbfs
632.endif
633
634.if ${MACHINE_ARCH} == "sparc64"
635_ath=		ath
636_ath_hal=	ath_hal
637_ath_rate_amrr=	ath_rate_amrr
638_ath_rate_onoe=	ath_rate_onoe
639_ath_rate_sample=ath_rate_sample
640_auxio=		auxio
641_em=		em
642_i2c=		i2c
643_igb=		igb
644_sound=		sound
645.if ${MK_ZFS} != "no" || defined(ALL_MODULES)
646_zfs=		zfs
647.endif
648.endif
649
650.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
651SUBDIR=${MODULES_OVERRIDE}
652.endif
653
654.for reject in ${WITHOUT_MODULES}
655SUBDIR:= ${SUBDIR:N${reject}}
656.endfor
657
658# Calling kldxref(8) for each module is expensive.
659.if !defined(NO_XREF)
660.MAKEFLAGS+=	-DNO_XREF
661afterinstall:
662	@if type kldxref >/dev/null 2>&1; then \
663		${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
664		kldxref ${DESTDIR}${KMODDIR}; \
665	fi
666.endif
667
668.include <bsd.subdir.mk>
669