# $FreeBSD$

.if exists(${.CURDIR}/../crypto) && !defined(NOCRYPT)
_random=	random
.endif

SUBDIR=	3dfx \
	accf_data \
	accf_http \
	agp \
	aha \
	aio \
	amr \
	an \
	aue \
	bge \
	bridge \
	cam \
	ccd \
	cd9660 \
	coda \
	cue \
	dc \
	de \
	digi \
	dummynet \
	ed \
	fdescfs \
	fdc \
	fxp \
	gx \
	if_disc \
	if_ef \
	if_gif \
	if_faith \
	if_ppp \
	if_sl \
	if_stf \
	if_tap \
	if_tun \
	if_vlan \
	ip6fw \
	ip_mroute_mod \
	ipfw \
	ispfw \
	joy \
	kue \
	lge \
	libiconv \
	libmchain \
	linprocfs \
	lnc \
	lomac \
	lpt \
	md \
	mii \
	mlx \
	msdosfs \
	nfsclient \
	nfsserver \
	nge \
	nmdm \
	ntfs \
	nullfs \
	pcn \
	plip \
	portalfs \
	ppbus \
	ppi \
	pps \
	procfs \
	pseudofs \
	${_random} \
	rl \
	rp \
	sf \
	sis \
	sk \
	sn \
	snp \
	sound \
	sppp \
	ste \
	sym \
	syscons \
	sysvipc \
	ti \
	tl \
	twe \
	tx \
	txp \
	ucom \
	udbp \
	ufm \
	ugen \
	uhid \
	ukbd \
	ulpt \
	umapfs \
	umass \
	umodem \
	ums \
	unionfs \
	uplcom \
	urio \
	usb \
	uscanner \
	uvscom \
	vinum \
	vpo \
	vr \
	vx \
	wb \
	xl

.if !defined(NO_IPFILTER)
SUBDIR+=ipfilter
.endif

#removed while KSE settles in:
#	ncp \
#	nwfs \
# XXX some of these can move to the general case when de-i386'ed
.if ${MACHINE_ARCH} == "i386"
SUBDIR+=aac \
	acpi \
	aic \
	ar \
	arcnet \
	apm \
	asr \
	atspeaker \
	bktr \
	ciss \
	cm \
	coff \
	el \
	em \
	fe \
	fpu \
	gnufpu \
	ibcs2 \
	iir \
	linux \
	ncv \
	nsp \
	mly \
	netgraph \
	oltr \
	pecoff \
	ray \
	s3 \
	sbni \
	scsi_low \
	smbfs \
	splash \
	sr \
	stg \
	streams \
	vesa \
	wi \
	xe
.endif

.if ${MACHINE} == "pc98"
SUBDIR+=pmc \
	snc
.endif

.if ${MACHINE_ARCH} == "alpha"
SUBDIR+=linux \
	osf1
.endif

.if defined(WANT_EXT2FS_MODULE)
SUBDIR+=ext2fs
.endif

.if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
SUBDIR=${MODULES_OVERRIDE}
.endif

# Calling kldxref(8) for each module is expensive.
.if !defined(NO_XREF)
.MAKEFLAGS:=	${.MAKEFLAGS} -DNO_XREF
afterinstall:
	-kldxref ${DESTDIR}${KMODDIR}
.endif

.include <bsd.subdir.mk>