Makefile revision 1.189
1#	$NetBSD: Makefile,v 1.189 2017/02/16 08:12:43 knakahara Exp $
2
3.include <bsd.own.mk>
4
5# For all platforms
6
7SUBDIR=		accf_dataready
8SUBDIR+=	accf_httpready
9SUBDIR+=	adosfs
10SUBDIR+=	aio
11SUBDIR+=	blowfish
12SUBDIR+=	bpf
13SUBDIR+=	bpf_filter
14SUBDIR+=	bufq_disksort
15SUBDIR+=	bufq_fcfs
16SUBDIR+=	bufq_priocscan
17SUBDIR+=	bufq_readprio
18SUBDIR+=	camellia
19SUBDIR+=	cast128
20SUBDIR+=	ccd
21SUBDIR+=	cd9660
22SUBDIR+=	cgd
23SUBDIR+=	chfs
24SUBDIR+=	clockctl
25SUBDIR+=	crypto
26SUBDIR+=	coda
27SUBDIR+=	coda5
28SUBDIR+=	compat
29SUBDIR+=	compat_ossaudio
30SUBDIR+=	coredump
31SUBDIR+=	dbcool
32SUBDIR+=	des
33SUBDIR+=	dk_subr
34SUBDIR+=	drvctl
35SUBDIR+=	efs
36SUBDIR+=	ext2fs
37SUBDIR+=	exec_script
38SUBDIR+=	fdesc
39SUBDIR+=	ffs
40SUBDIR+=	filecore
41SUBDIR+=	filemon
42SUBDIR+=	flash
43SUBDIR+=	fss
44SUBDIR+=	gpio
45SUBDIR+=	gpioiic
46SUBDIR+=	gpioow
47SUBDIR+=	gpiosim
48SUBDIR+=	hfs
49SUBDIR+=	hythygtemp
50SUBDIR+=	i2cexec
51SUBDIR+=	i2c_bitbang
52SUBDIR+=	if_agr
53SUBDIR+=	if_axe
54SUBDIR+=	if_axen
55SUBDIR+=	if_faith
56SUBDIR+=	if_gif
57SUBDIR+=	if_gre
58SUBDIR+=	if_l2tp
59SUBDIR+=	if_loop
60SUBDIR+=	if_mpls
61SUBDIR+=	if_npflog
62SUBDIR+=	if_ppp
63SUBDIR+=	if_pppoe
64SUBDIR+=	if_sl
65SUBDIR+=	if_smsc
66SUBDIR+=	if_srt
67SUBDIR+=	if_stf
68SUBDIR+=	if_strip
69SUBDIR+=	if_tun tun
70SUBDIR+=	if_vlan
71SUBDIR+=	iic
72SUBDIR+=	ipl
73SUBDIR+=	kernfs
74SUBDIR+=	layerfs
75SUBDIR+=	lfs
76SUBDIR+=	lua
77SUBDIR+=	luasystm
78SUBDIR+=	luapmf
79SUBDIR+=	mfs
80SUBDIR+=	miiverbose
81SUBDIR+=	miniroot
82SUBDIR+=	mqueue
83SUBDIR+=	msdos
84SUBDIR+=	nand
85SUBDIR+=	nandemulator
86SUBDIR+=	nfs
87SUBDIR+=	nfsserver
88SUBDIR+=	nilfs
89SUBDIR+=	npf
90SUBDIR+=	npf_alg_icmp
91SUBDIR+=	npf_ext_log
92SUBDIR+=	npf_ext_normalize
93SUBDIR+=	npf_ext_rndblock
94SUBDIR+=	ntfs
95SUBDIR+=	null
96SUBDIR+=	onewire
97SUBDIR+=	opencrypto
98SUBDIR+=	overlay
99SUBDIR+=	pciverbose
100SUBDIR+=	pf
101SUBDIR+=	ppp_bsdcomp
102SUBDIR+=	ppp_deflate
103SUBDIR+=	procfs
104SUBDIR+=	ptrace
105SUBDIR+=	ptrace_common
106SUBDIR+=	ptyfs
107SUBDIR+=	puffs
108SUBDIR+=	putter
109SUBDIR+=	raid
110SUBDIR+=	scsiverbose
111SUBDIR+=	sdtemp
112SUBDIR+=	secmodel_bsd44
113SUBDIR+=	secmodel_extensions
114SUBDIR+=	secmodel_overlay
115SUBDIR+=	securelevel
116SUBDIR+=	skipjack
117SUBDIR+=	slcompress
118SUBDIR+=	smbfs
119SUBDIR+=	spdmem
120SUBDIR+=	spkr
121SUBDIR+=	sppp_subr
122SUBDIR+=	sysmon
123SUBDIR+=	sysmon_envsys
124SUBDIR+=	sysmon_power
125SUBDIR+=	sysmon_taskq
126SUBDIR+=	sysmon_wdog
127SUBDIR+=	sysvbfs
128SUBDIR+=	sysv_ipc
129SUBDIR+=	suser
130SUBDIR+=	swcrypto
131SUBDIR+=	swsensor
132SUBDIR+=	swwdog
133SUBDIR+=	tmpfs
134SUBDIR+=	uatp
135SUBDIR+=	udf
136SUBDIR+=	umap
137SUBDIR+=	union
138SUBDIR+=	usbverbose
139SUBDIR+=	vcoda
140SUBDIR+=	v7fs
141SUBDIR+=	vnd
142SUBDIR+=	wapbl
143SUBDIR+=	zlib
144SUBDIR+=	tprof
145.if (defined(NOTYET))
146SUBDIR+=	hifn		# Builds on architectures with PCI bus
147SUBDIR+=	unionfs
148.endif
149.if ${MKBINUTILS} != "no"
150SUBDIR+=	xldscripts
151.endif
152
153# Machine dependent section
154.if ${MACHINE_ARCH} == "i386" || \
155    ${MACHINE_CPU} == "m68k"
156SUBDIR+=	exec_aout
157.endif
158
159.if ${MACHINE_ARCH} != "alpha" && \
160    ${MACHINE_CPU} != "aarch64" && \
161    ${MACHINE_ARCH} != "ia64"
162SUBDIR+=	exec_elf32
163.endif
164
165.if ${MACHINE_CPU} == "aarch64" || \
166    ${MACHINE_ARCH} == "alpha" || \
167    ${MACHINE_ARCH} == "ia64" || \
168    ${MACHINE_ARCH} == "sparc64" || \
169    ${MACHINE_ARCH} == "x86_64"
170SUBDIR+=	exec_elf64
171.endif
172
173.if ${MACHINE_ARCH} == "i386" || \
174    ${MACHINE_ARCH} == "x86_64"
175SUBDIR+=	amdtemp
176SUBDIR+=	coretemp
177SUBDIR+=	est
178SUBDIR+=	hdafg
179SUBDIR+=	hdaudio
180SUBDIR+=	hdaudio_pci
181SUBDIR+=	hdaudioverbose
182SUBDIR+=	hpet
183SUBDIR+=	odcm
184SUBDIR+=	powernow
185SUBDIR+=	tco
186SUBDIR+=	tprof_pmi
187SUBDIR+=	tprof_amdpmi
188SUBDIR+=	vmt
189.endif
190
191.if ${MACHINE_ARCH} == "i386" || \
192    ${MACHINE_ARCH} == "x86_64"
193SUBDIR+=	ubsec		# Builds on architectures with PCI bus
194.endif
195
196.if ${MKSLJIT} != "no"
197# No modules for arm, mips and powerpc yet.
198.if ${MACHINE_ARCH} == "i386" || \
199    ${MACHINE_ARCH} == "x86_64" || \
200    ${MACHINE_ARCH} == "sparc"
201SUBDIR+=	bpfjit
202SUBDIR+=	sljit
203.endif
204.endif
205
206#
207# ACPI modules
208#
209.if ${MACHINE_ARCH} == "i386" || \
210    ${MACHINE_ARCH} == "ia64" || \
211    ${MACHINE_ARCH} == "x86_64"
212SUBDIR+=	acpiverbose
213.endif
214
215.if ${MACHINE_ARCH} == "i386" || \
216    ${MACHINE_ARCH} == "x86_64"
217SUBDIR+=	acpiacad
218SUBDIR+=	acpibat
219SUBDIR+=	acpibut
220SUBDIR+=	acpicpu
221SUBDIR+=	acpidalb
222SUBDIR+=	acpifan
223SUBDIR+=	acpilid
224SUBDIR+=	acpipmtr
225SUBDIR+=	acpitz
226SUBDIR+=	acpivga
227SUBDIR+=	acpiwdrt
228SUBDIR+=	acpiwmi
229SUBDIR+=	aibs
230SUBDIR+=	asus
231SUBDIR+=	fujbp
232SUBDIR+=	fujhk
233SUBDIR+=	hpacel
234SUBDIR+=	hpqlb
235SUBDIR+=	thinkpad
236SUBDIR+=	wmidell
237SUBDIR+=	wmieeepc
238SUBDIR+=	wmihp
239SUBDIR+=	wmimsi
240.endif
241
242.if ${MACHINE_CPU} == "arm" \
243    || (!empty(MACHINE_ARCH:Mmips64*) && !defined(BSD_MK_COMPAT_FILE))
244SUBDIR+=	compat_netbsd32
245SUBDIR+=	compat_netbsd32_mqueue
246SUBDIR+=	compat_netbsd32_nfssrv
247SUBDIR+=	compat_netbsd32_ptrace
248SUBDIR+=	compat_netbsd32_sysvipc
249.endif
250
251.if ${MACHINE_ARCH} == "x86_64"
252SUBDIR+=	compat_linux32
253SUBDIR+=	compat_netbsd32
254SUBDIR+=	compat_netbsd32_mqueue
255SUBDIR+=	compat_netbsd32_nfssrv
256SUBDIR+=	compat_netbsd32_ptrace
257SUBDIR+=	compat_netbsd32_sysvipc
258.endif
259
260.if ${MACHINE_ARCH} == "i386"
261SUBDIR+=	ati_pcigart
262SUBDIR+=	compat_freebsd
263SUBDIR+=	compat_ibcs2
264SUBDIR+=	compat_svr4
265SUBDIR+=	mach64drm
266SUBDIR+=	mgadrm
267SUBDIR+=	nsclpcsio
268SUBDIR+=	padlock
269SUBDIR+=	r128drm
270SUBDIR+=	radeondrm
271SUBDIR+=	savagedrm
272SUBDIR+=	sisdrm
273SUBDIR+=	tdfxdrm
274SUBDIR+=	viac7temp
275SUBDIR+=	viadrm
276SUBDIR+=	viadrmums
277.endif
278
279.if ${MACHINE_ARCH} == "i386" || \
280    ${MACHINE_ARCH} == "x86_64"
281SUBDIR+=	azalia
282SUBDIR+=	compat_linux
283SUBDIR+=	drm
284SUBDIR+=	drmkms
285SUBDIR+=	drmkms_linux
286SUBDIR+=	drmkms_pci
287SUBDIR+=	i915drm
288SUBDIR+=	i915drmkms
289SUBDIR+=	pad
290#
291# ISA modules
292#
293SUBDIR+=	aps
294SUBDIR+=	finsio
295SUBDIR+=	itesio
296SUBDIR+=	lm
297SUBDIR+=	lm_isa
298SUBDIR+=	lm_isa_common
299SUBDIR+=	lm_wbsio
300SUBDIR+=	wbsio
301.endif
302
303.if ${MACHINE_CPU} == "m68k"
304SUBDIR+=	compat_aoutm68k
305#SUBDIR+=	compat_linux
306#SUBDIR+=	compat_sunos
307#SUBDIR+=	compat_svr4
308.endif
309
310.if ${MACHINE_ARCH} == "i386" || \
311    ${MACHINE_ARCH} == "x86_64" || \
312    ${MACHINE_ARCH} == "sparc64"
313SUBDIR+=	pwdog
314.endif
315
316.include <bsd.own.mk>
317
318#
319# NetBSD/usermode support
320#
321.if ${MACHINE_ARCH} == "i386" || \
322    ${MACHINE_ARCH} == "x86_64"
323SUBDIR+=	../arch/usermode/modules/syscallemu
324.endif
325
326# we need our device mapper for LVM
327.if (${MKLVM} != "no")
328SUBDIR+= 	dm
329.endif
330
331.if (${MKDTRACE} != "no")
332SUBDIR+=	cyclic
333SUBDIR+=	dtrace
334.endif
335
336# we need solaris for the dtrace and zfs modules
337.if (${MKDTRACE} != "no" || ${MKZFS} != "no")
338SUBDIR+=        solaris
339.endif
340
341.if (${MKZFS} != "no")
342SUBDIR+=	zfs
343.endif
344
345.if (${MKCOMPATMODULES} != "no")
346SUBDIR+=	arch
347.endif
348
349#
350# DTV modules
351#
352SUBDIR+=	dtv
353SUBDIR+=	dtv_math
354.if ${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH} == "x86_64"
355# tuners/demods
356SUBDIR+=	au8522
357SUBDIR+=	cx24227
358SUBDIR+=	lg3303
359SUBDIR+=	mt2131
360SUBDIR+=	nxt2k
361SUBDIR+=	tvpll
362SUBDIR+=	xc3028
363SUBDIR+=	xc5k
364SUBDIR+=	zl10353
365# hardware drivers
366SUBDIR+=	auvitek
367SUBDIR+=	coram
368SUBDIR+=	cxdtv
369SUBDIR+=	emdtv
370.endif
371
372.if (${MKISCSI} != "no")
373SUBDIR+=	iscsi
374.endif
375
376# For now, all of these are disabled, pending resolution of how to deal
377# with attachment-specific modules and bus-specific modules (as opposed
378# to machine- or architecture-specific modules)
379
380.if 0
381SUBDIR+=	aac
382SUBDIR+=	amr
383SUBDIR+=	ataraid
384SUBDIR+=	cac
385SUBDIR+=	cac_eisa
386SUBDIR+=	cac_pci
387SUBDIR+=	if_vioif
388SUBDIR+=	ld
389SUBDIR+=	ld_aac
390SUBDIR+=	ld_amr
391SUBDIR+=	ld_ataraid
392SUBDIR+=	ld_cac
393SUBDIR+=	ld_icp
394SUBDIR+=	ld_mlx
395SUBDIR+=	ld_sdmmc
396SUBDIR+=	ld_twa
397SUBDIR+=	ld_twe
398SUBDIR+=	ld_virtio
399SUBDIR+=	mlx
400SUBDIR+=	mlx_eisa
401SUBDIR+=	mlx_pci
402SUBDIR+=	ld_nvme
403SUBDIR+=	nvme
404SUBDIR+=	twa
405SUBDIR+=	twe
406SUBDIR+=	viomb
407SUBDIR+=	virtio
408.endif
409
410SUBDIR+=	examples	# build these regularly to avoid bit-rot
411
412.include <bsd.subdir.mk>
413