xref: /freebsd/sys/modules/Makefile (revision 9c999a259f00b35f0467acd351fea9157ed7e1e4)
1# $FreeBSD$
2
3SYSDIR?=${SRCTOP}/sys
4.include "${SYSDIR}/conf/kern.opts.mk"
5
6SUBDIR_PARALLEL=
7
8# Modules that include binary-only blobs of microcode should be selectable by
9# MK_SOURCELESS_UCODE option (see below).
10
11.include "${SYSDIR}/conf/config.mk"
12
13.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
14SUBDIR=${MODULES_OVERRIDE}
15.else
16SUBDIR=	\
17	${_3dfx} \
18	${_3dfx_linux} \
19	${_aac} \
20	${_aacraid} \
21	accf_data \
22	accf_dns \
23	accf_http \
24	acl_nfs4 \
25	acl_posix1e \
26	${_acpi} \
27	ae \
28	${_aesni} \
29	age \
30	${_agp} \
31	ahci \
32	aic7xxx \
33	alc \
34	ale \
35	alq \
36	${_amd_ecc_inject} \
37	${_amdgpio} \
38	${_amdsbwd} \
39	${_amdsmn} \
40	${_amdtemp} \
41	amr \
42	${_aout} \
43	${_arcmsr} \
44	${_allwinner} \
45	${_armv8crypto} \
46	${_asmc} \
47	ata \
48	ath \
49	ath_dfs \
50	ath_hal \
51	ath_hal_ar5210 \
52	ath_hal_ar5211 \
53	ath_hal_ar5212 \
54	ath_hal_ar5416 \
55	ath_hal_ar9300 \
56	ath_main \
57	ath_rate \
58	ath_pci \
59	${_autofs} \
60	axgbe \
61	backlight \
62	${_bce} \
63	${_bcm283x_clkman} \
64	${_bcm283x_pwm} \
65	bfe \
66	bge \
67	bhnd \
68	${_bxe} \
69	${_bios} \
70	${_blake2} \
71	bnxt \
72	bridgestp \
73	bwi \
74	bwn \
75	${_bytgpio} \
76	${_chvgpio} \
77	cam \
78	${_cardbus} \
79	${_carp} \
80	cas \
81	${_cbb} \
82	cc \
83	${_ccp} \
84	cd9660 \
85	cd9660_iconv \
86	${_ce} \
87	${_cfi} \
88	${_chromebook_platform} \
89	${_ciss} \
90	${_coretemp} \
91	${_cp} \
92	${_cpsw} \
93	${_cpuctl} \
94	${_cpufreq} \
95	${_crypto} \
96	${_cryptodev} \
97	ctl \
98	${_cxgb} \
99	${_cxgbe} \
100	dc \
101	dcons \
102	dcons_crom \
103	${_dpdk_lpm4} \
104	${_dpdk_lpm6} \
105	${_dpms} \
106	dummynet \
107	${_dwwdt} \
108	${_e6000sw} \
109	${_efirt} \
110	${_em} \
111	${_ena} \
112	${_enetc} \
113	${_enetc_mdio} \
114	esp \
115	${_et} \
116	evdev \
117	${_exca} \
118	ext2fs \
119	fdc \
120	fdescfs \
121	${_felix} \
122	${_ffec} \
123	${_fib_dxr} \
124	filemon \
125	firewire \
126	firmware \
127	${_ftwd} \
128	fusefs \
129	${_fxp} \
130	gem \
131	geom \
132	${_glxiic} \
133	${_glxsb} \
134	gpio \
135	hid \
136	hifn \
137	${_hpt27xx} \
138	${_hptiop} \
139	${_hptmv} \
140	${_hptnr} \
141	${_hptrr} \
142	hwpmc \
143	${_hwpmc_mips24k} \
144	${_hwpmc_mips74k} \
145	${_hyperv} \
146	i2c \
147	${_iavf} \
148        ${_ibcore} \
149	${_ichwd} \
150	${_ice} \
151	${_ice_ddp} \
152	${_ida} \
153	if_bridge \
154	if_disc \
155	if_edsc \
156	${_if_enc} \
157	if_epair \
158	${_if_gif} \
159	${_if_gre} \
160	${_if_me} \
161	if_infiniband \
162	if_lagg \
163	${_if_stf} \
164	if_tuntap \
165	if_vlan \
166	if_vxlan \
167	iflib \
168	${_igc} \
169	${_iir} \
170	imgact_binmisc \
171	${_intelspi} \
172	${_io} \
173	${_ioat} \
174        ${_ipoib} \
175	${_ipdivert} \
176	${_ipfilter} \
177	${_ipfw} \
178	ipfw_nat \
179	${_ipfw_nat64} \
180	${_ipfw_nptv6} \
181	${_ipfw_pmod} \
182	${_ipmi} \
183	ip6_mroute_mod \
184	ip_mroute_mod \
185	${_ips} \
186	${_ipsec} \
187	${_ipw} \
188	${_ipwfw} \
189	${_isci} \
190	${_iser} \
191	isp \
192	${_ispfw} \
193	${_itwd} \
194	${_iwi} \
195	${_iwifw} \
196	${_iwm} \
197	${_iwmfw} \
198	${_iwn} \
199	${_iwnfw} \
200	${_ix} \
201	${_ixv} \
202	${_ixl} \
203	jme \
204	kbdmux \
205	kgssapi \
206	kgssapi_krb5 \
207	khelp \
208	krpc \
209	ksyms \
210	le \
211	lge \
212	libalias \
213	libiconv \
214	libmchain \
215	lindebugfs \
216	linuxkpi \
217	${_lio} \
218	lpt \
219	mac_biba \
220	mac_bsdextended \
221	mac_ifoff \
222	mac_lomac \
223	mac_mls \
224	mac_none \
225	mac_ntpd \
226	mac_partition \
227	mac_portacl \
228	mac_seeotheruids \
229	mac_stub \
230	mac_test \
231	${_malo} \
232	${_mana} \
233	md \
234	mdio \
235	${_mgb} \
236	mem \
237	mfi \
238	mii \
239	mlx \
240	mlxfw \
241	${_mlx4} \
242	${_mlx4ib} \
243	${_mlx4en} \
244	${_mlx5} \
245	${_mlx5en} \
246	${_mlx5ib} \
247	${_mly} \
248	mmc \
249	mmcsd \
250	${_mpr} \
251	${_mps} \
252	mpt \
253	mqueue \
254	mrsas \
255	msdosfs \
256	msdosfs_iconv \
257	msk \
258	${_mthca} \
259	mvs \
260	mwl \
261	${_mwlfw} \
262	mxge \
263	my \
264	${_nctgpio} \
265	${_neta} \
266	${_netgraph} \
267	${_nfe} \
268	nfscl \
269	nfscommon \
270	nfsd \
271	nfslockd \
272	nfssvc \
273	nge \
274	nmdm \
275	nullfs \
276	${_ntb} \
277	${_nvd} \
278	${_nvdimm} \
279	${_nvme} \
280	${_nvram} \
281	oce \
282	${_ocs_fc} \
283	${_ossl} \
284	otus \
285	${_otusfw} \
286	ow \
287	${_padlock} \
288	${_padlock_rng} \
289	${_pchtherm} \
290	${_pcfclock} \
291	${_pf} \
292	${_pflog} \
293	${_pfsync} \
294	plip \
295	${_pms} \
296	ppbus \
297	ppc \
298	ppi \
299	pps \
300	procfs \
301	proto \
302	pseudofs \
303	${_pst} \
304	pty  \
305	puc \
306	pwm \
307	${_qat} \
308	${_qatfw} \
309	${_qlxge} \
310	${_qlxgb} \
311	${_qlxgbe} \
312	${_qlnx} \
313	ral \
314	${_ralfw} \
315	${_random_fortuna} \
316	${_random_other} \
317	rc4 \
318	${_rdma} \
319	${_rdrand_rng} \
320	re \
321	rl \
322	${_rockchip} \
323	rtsx \
324	rtwn \
325	rtwn_pci \
326	rtwn_usb \
327	${_rtwnfw} \
328	${_s3} \
329	${_safe} \
330	safexcel \
331	${_sbni} \
332	scc \
333	${_sctp} \
334	sdhci \
335	${_sdhci_acpi} \
336	${_sdhci_fdt} \
337	sdhci_pci \
338	sdio \
339	sem \
340	send \
341	${_sfxge} \
342	sge \
343	${_sgx} \
344	${_sgx_linux} \
345	siftr \
346	siis \
347	sis \
348	sk \
349	${_smartpqi} \
350	smbfs \
351	snp \
352	sound \
353	${_speaker} \
354	spi \
355	${_splash} \
356	${_sppp} \
357	ste \
358	stge \
359	${_sume} \
360	${_superio} \
361	${_p2sb} \
362	${_sym} \
363	${_syscons} \
364	sysvipc \
365	tcp \
366	${_ti} \
367	tmpfs \
368	${_toecore} \
369	${_tpm} \
370	${_twa} \
371	twe \
372	tws \
373	uart \
374	udf \
375	udf_iconv \
376	ufs \
377	uinput \
378	unionfs \
379	usb \
380	${_vesa} \
381	virtio \
382	vge \
383	${_viawd} \
384	videomode \
385	vkbd \
386	${_vmd} \
387	${_vmm} \
388	${_vmware} \
389	vr \
390	vte \
391	${_wbwd} \
392	wlan \
393	wlan_acl \
394	wlan_amrr \
395	wlan_ccmp \
396	wlan_rssadapt \
397	wlan_tkip \
398	wlan_wep \
399	wlan_xauth \
400	${_wpi} \
401	${_wpifw} \
402	${_x86bios} \
403	xdr \
404	xl \
405	xz \
406	zlib
407
408.if ${MK_AUTOFS} != "no" || defined(ALL_MODULES)
409_autofs=	autofs
410.endif
411
412.if ${MK_CDDL} != "no" || defined(ALL_MODULES)
413.if (${MACHINE_CPUARCH} != "arm" || ${MACHINE_ARCH:Marmv[67]*} != "") && \
414	${MACHINE_CPUARCH} != "mips"
415.if ${KERN_OPTS:MKDTRACE_HOOKS}
416SUBDIR+=	dtrace
417.endif
418.endif
419SUBDIR+=	opensolaris
420.endif
421
422.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
423.if exists(${SRCTOP}/sys/opencrypto)
424_crypto=	crypto
425_cryptodev=	cryptodev
426_random_fortuna=random_fortuna
427_random_other=	random_other
428.endif
429.endif
430
431.if ${MK_CUSE} != "no" || defined(ALL_MODULES)
432SUBDIR+=	cuse
433.endif
434
435.if ${MK_EFI} != "no"
436.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64"
437_efirt=		efirt
438.endif
439.endif
440
441.if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \
442	defined(ALL_MODULES)
443_carp=		carp
444_toecore=	toecore
445_if_enc=	if_enc
446_if_gif=	if_gif
447_if_gre=	if_gre
448_ipfw_pmod=	ipfw_pmod
449.if ${KERN_OPTS:MIPSEC_SUPPORT} && !${KERN_OPTS:MIPSEC}
450_ipsec=		ipsec
451.endif
452.if ${KERN_OPTS:MSCTP_SUPPORT} || ${KERN_OPTS:MSCTP}
453_sctp=		sctp
454.endif
455.endif
456
457.if (${MK_INET_SUPPORT} != "no" && ${MK_INET6_SUPPORT} != "no") || \
458	defined(ALL_MODULES)
459_if_stf=	if_stf
460.endif
461
462.if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES)
463_if_me=		if_me
464_ipdivert=	ipdivert
465_ipfw=		ipfw
466.if ${MK_INET6_SUPPORT} != "no" || defined(ALL_MODULES)
467_ipfw_nat64=	ipfw_nat64
468.endif
469.endif
470
471.if ${MK_INET6_SUPPORT} != "no" || defined(ALL_MODULES)
472_ipfw_nptv6=	ipfw_nptv6
473.endif
474
475.if ${MK_IPFILTER} != "no" || defined(ALL_MODULES)
476_ipfilter=	ipfilter
477.endif
478
479.if ${MK_INET_SUPPORT} != "no" && ${KERN_OPTS:MFIB_ALGO}
480_dpdk_lpm4=	dpdk_lpm4
481_fib_dxr=	fib_dxr
482.endif
483
484.if ${MK_INET6_SUPPORT} != "no" && ${KERN_OPTS:MFIB_ALGO}
485_dpdk_lpm6=	dpdk_lpm6
486.endif
487
488.if ${MK_ISCSI} != "no" || defined(ALL_MODULES)
489SUBDIR+=	cfiscsi
490SUBDIR+=	iscsi
491SUBDIR+=	iscsi_initiator
492.endif
493
494.if !empty(OPT_FDT)
495SUBDIR+=	fdt
496.endif
497
498# Linuxulator
499.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \
500    ${MACHINE_CPUARCH} == "i386"
501SUBDIR+=	linprocfs
502SUBDIR+=	linsysfs
503.endif
504.if ${MACHINE_CPUARCH} == "amd64" || ${MACHINE_CPUARCH} == "i386"
505SUBDIR+=	linux
506.endif
507.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64"
508SUBDIR+=	linux64
509SUBDIR+=	linux_common
510.endif
511
512.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "amd64" || \
513    ${MACHINE_CPUARCH} == "i386"
514_ena=		ena
515.if ${MK_OFED} != "no" || defined(ALL_MODULES)
516_ibcore=	ibcore
517_ipoib=		ipoib
518_iser=		iser
519.endif
520_ipmi=		ipmi
521_mlx4=		mlx4
522_mlx5=		mlx5
523.if (${MK_INET_SUPPORT} != "no" && ${MK_INET6_SUPPORT} != "no") || \
524	defined(ALL_MODULES)
525_mlx4en=	mlx4en
526_mlx5en=	mlx5en
527.endif
528.if ${MK_OFED} != "no" || defined(ALL_MODULES)
529_mthca=		mthca
530_mlx4ib=	mlx4ib
531_mlx5ib=	mlx5ib
532.endif
533_ossl=		ossl
534_vmware=	vmware
535.endif
536
537.if ${MK_NETGRAPH} != "no" || defined(ALL_MODULES)
538_netgraph=	netgraph
539.endif
540
541.if (${MK_PF} != "no" && (${MK_INET_SUPPORT} != "no" || \
542	${MK_INET6_SUPPORT} != "no")) || defined(ALL_MODULES)
543_pf=		pf
544_pflog=		pflog
545.if ${MK_INET_SUPPORT} != "no"
546_pfsync=	pfsync
547.endif
548.endif
549
550.if ${MK_SOURCELESS_UCODE} != "no"
551_bce=		bce
552_fxp=		fxp
553_ispfw=		ispfw
554_ti=		ti
555
556.if ${MACHINE_CPUARCH} != "mips"
557_mwlfw=		mwlfw
558_otusfw=	otusfw
559_ralfw=		ralfw
560_rtwnfw=	rtwnfw
561.endif
562.endif
563
564.if ${MK_SOURCELESS_UCODE} != "no" && ${MACHINE_CPUARCH} != "arm" && \
565	${MACHINE_CPUARCH} != "mips" && \
566	${MACHINE_ARCH} != "powerpc" && ${MACHINE_ARCH} != "powerpcspe" && \
567	${MACHINE_CPUARCH} != "riscv"
568_cxgbe=		cxgbe
569.endif
570
571.if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "arm64"
572_ice=		ice
573.if ${MK_SOURCELESS_UCODE} != "no"
574_ice_ddp=	ice_ddp
575.endif
576.endif
577
578# These rely on 64bit atomics
579.if ${MACHINE_ARCH} != "powerpc" && ${MACHINE_ARCH} != "powerpcspe" && \
580	${MACHINE_CPUARCH} != "mips"
581_mps=		mps
582_mpr=		mpr
583.endif
584
585.if ${MK_TESTS} != "no" || defined(ALL_MODULES)
586SUBDIR+=	tests
587.endif
588
589.if ${MK_ZFS} != "no" || (defined(ALL_MODULES)  && ${MACHINE_CPUARCH} != "powerpc")
590SUBDIR+=	zfs
591.endif
592
593.if (${MACHINE_CPUARCH} == "mips" && ${MACHINE_ARCH:Mmips64} == "")
594_hwpmc_mips24k=	hwpmc_mips24k
595_hwpmc_mips74k=	hwpmc_mips74k
596.endif
597
598.if ${MACHINE_CPUARCH} != "aarch64" && ${MACHINE_CPUARCH} != "arm" && \
599	${MACHINE_CPUARCH} != "mips" && ${MACHINE_CPUARCH} != "powerpc" && \
600	${MACHINE_CPUARCH} != "riscv"
601_syscons=	syscons
602.endif
603
604.if ${MACHINE_CPUARCH} != "mips"
605# no BUS_SPACE_UNSPECIFIED
606# No barrier instruction support (specific to this driver)
607_sym=		sym
608# intr_disable() is a macro, causes problems
609.if ${MK_SOURCELESS_UCODE} != "no"
610_cxgb=		cxgb
611.endif
612.endif
613
614.if ${MACHINE_CPUARCH} == "aarch64"
615_allwinner=	allwinner
616_armv8crypto=	armv8crypto
617_dwwdt=		dwwdt
618_em=		em
619_enetc=		enetc
620_enetc_mdio=	enetc_mdio
621_felix=		felix
622_rockchip=	rockchip
623.endif
624
625.if ${MACHINE_CPUARCH} == "aarch64" || ${MACHINE_CPUARCH} == "arm"
626_sdhci_fdt=	sdhci_fdt
627_e6000sw=	e6000sw
628_neta=		neta
629.endif
630
631.if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64"
632_agp=		agp
633_aout=		aout
634_bios=		bios
635.if ${MK_SOURCELESS_UCODE} != "no"
636_bxe=		bxe
637.endif
638_cardbus=	cardbus
639_cbb=		cbb
640_cpuctl=	cpuctl
641_cpufreq=	cpufreq
642_dpms=		dpms
643_em=		em
644_et=		et
645_ftwd=		ftwd
646_exca=		exca
647_igc=		igc
648_io=		io
649_itwd=		itwd
650_ix=		ix
651_ixv=		ixv
652.if ${MK_SOURCELESS_UCODE} != "no"
653_lio=		lio
654.endif
655_mana=		mana
656_mgb=		mgb
657_nctgpio=	nctgpio
658_ntb=		ntb
659_ocs_fc=	ocs_fc
660_qat=		qat
661_qatfw=		qatfw
662.if ${MK_OFED} != "no" || defined(ALL_MODULES)
663_rdma=		rdma
664.endif
665_safe=		safe
666_speaker=	speaker
667_splash=	splash
668_sppp=		sppp
669_p2sb=		p2sb
670_wbwd=		wbwd
671
672_aac=		aac
673_aacraid=	aacraid
674_acpi=		acpi
675.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
676_aesni=		aesni
677.endif
678_amd_ecc_inject=amd_ecc_inject
679_amdsbwd=	amdsbwd
680_amdsmn=	amdsmn
681_amdtemp=	amdtemp
682_arcmsr=	arcmsr
683_asmc=		asmc
684.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
685_blake2=	blake2
686.endif
687_bytgpio=	bytgpio
688_chvgpio=	chvgpio
689_ciss=		ciss
690_chromebook_platform=	chromebook_platform
691_coretemp=	coretemp
692.if ${MK_SOURCELESS_HOST} != "no" && empty(KCSAN_ENABLED)
693_hpt27xx=	hpt27xx
694.endif
695_hptiop=	hptiop
696.if ${MK_SOURCELESS_HOST} != "no" && empty(KCSAN_ENABLED)
697_hptmv=		hptmv
698_hptnr=		hptnr
699_hptrr=		hptrr
700.endif
701_hyperv=	hyperv
702_ichwd=		ichwd
703_ida=		ida
704_iir=		iir
705_intelspi=	intelspi
706_ips=		ips
707_isci=		isci
708_ipw=		ipw
709_iwi=		iwi
710_iwm=		iwm
711_iwn=		iwn
712.if ${MK_SOURCELESS_UCODE} != "no"
713_ipwfw=		ipwfw
714_iwifw=		iwifw
715_iwmfw=		iwmfw
716_iwnfw=		iwnfw
717.endif
718_mly=		mly
719_nfe=		nfe
720_nvd=		nvd
721_nvme=		nvme
722_nvram=		nvram
723.if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
724_padlock=	padlock
725_padlock_rng=	padlock_rng
726_rdrand_rng=	rdrand_rng
727.endif
728_pchtherm = pchtherm
729_s3=		s3
730_sdhci_acpi=	sdhci_acpi
731_superio=	superio
732_tpm=		tpm
733_twa=		twa
734_vesa=		vesa
735_viawd=		viawd
736_vmd=		vmd
737_wpi=		wpi
738.if ${MK_SOURCELESS_UCODE} != "no"
739_wpifw=		wpifw
740.endif
741_x86bios=	x86bios
742.endif
743
744.if ${MACHINE_CPUARCH} == "amd64"
745_amdgpio=	amdgpio
746_ccp=		ccp
747_iavf=		iavf
748_ioat=		ioat
749_ixl=		ixl
750_nvdimm=	nvdimm
751_pms=		pms
752_qlxge=		qlxge
753_qlxgb=		qlxgb
754_sume=		sume
755.if ${MK_SOURCELESS_UCODE} != "no"
756_qlxgbe=	qlxgbe
757_qlnx=		qlnx
758.endif
759_sfxge=		sfxge
760_sgx=		sgx
761_sgx_linux=	sgx_linux
762_smartpqi=	smartpqi
763_p2sb=		p2sb
764
765.if ${MK_BHYVE} != "no" || defined(ALL_MODULES)
766.if ${KERN_OPTS:MSMP}
767_vmm=		vmm
768.endif
769.endif
770.endif
771
772.if ${MACHINE_CPUARCH} == "i386"
773# XXX some of these can move to the general case when de-i386'ed
774# XXX some of these can move now, but are untested on other architectures.
775_3dfx=		3dfx
776_3dfx_linux=	3dfx_linux
777.if ${MK_SOURCELESS_HOST} != "no"
778_ce=		ce
779.endif
780.if ${MK_SOURCELESS_HOST} != "no"
781_cp=		cp
782.endif
783_glxiic=	glxiic
784_glxsb=		glxsb
785_pcfclock=	pcfclock
786_pst=		pst
787_sbni=		sbni
788.endif
789
790.if ${MACHINE_ARCH} == "armv7"
791_cfi=		cfi
792_cpsw=		cpsw
793.endif
794
795.if ${MACHINE_CPUARCH} == "powerpc"
796_aacraid=	aacraid
797_agp=		agp
798_an=		an
799_cardbus=	cardbus
800_cbb=		cbb
801_cfi=		cfi
802_cpufreq=	cpufreq
803_exca=		exca
804_ffec=		ffec
805_nvd=		nvd
806_nvme=		nvme
807.endif
808
809.if ${MACHINE_ARCH:Mpowerpc64*} != ""
810_ipmi=		ipmi
811_ixl=		ixl
812_nvram=		opal_nvram
813.endif
814.if ${MACHINE_CPUARCH} == "powerpc" && ${MACHINE_ARCH} != "powerpcspe"
815# Don't build powermac_nvram for powerpcspe, it's never supported.
816_nvram+=	powermac_nvram
817.endif
818
819.endif
820
821.if ${MACHINE_ARCH:Marmv[67]*} != "" || ${MACHINE_CPUARCH} == "aarch64"
822_bcm283x_clkman=  bcm283x_clkman
823_bcm283x_pwm=  bcm283x_pwm
824.endif
825
826.if !(${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} < 110000)
827# LLVM 10 crashes when building if_malo_pci.c, fixed in LLVM11:
828# https://bugs.llvm.org/show_bug.cgi?id=44351
829_malo=	malo
830.endif
831
832SUBDIR+=${MODULES_EXTRA}
833
834.for reject in ${WITHOUT_MODULES}
835SUBDIR:= ${SUBDIR:N${reject}}
836.endfor
837
838# Calling kldxref(8) for each module is expensive.
839.if !defined(NO_XREF)
840.MAKEFLAGS+=	-DNO_XREF
841afterinstall: .PHONY
842	@if type kldxref >/dev/null 2>&1; then \
843		${ECHO} ${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
844		${KLDXREF_CMD} ${DESTDIR}${KMODDIR}; \
845	fi
846.endif
847
848SUBDIR:= ${SUBDIR:u:O}
849
850.include <bsd.subdir.mk>
851