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