]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sys/modules/Makefile
Merge the following from ^/projects/release-vmimage:
[FreeBSD/FreeBSD.git] / sys / modules / Makefile
1 # $FreeBSD$
2
3 SYSDIR?=${.CURDIR}/..
4 .include "${SYSDIR}/conf/kern.opts.mk"
5
6 SUBDIR_PARALLEL=
7
8 # Modules that include binary-only blobs of microcode should be selectable by
9 # MK_SOURCELESS_UCODE option (see below).
10
11 .if defined(MODULES_OVERRIDE) && !defined(ALL_MODULES)
12 SUBDIR=${MODULES_OVERRIDE}
13 .else
14 SUBDIR= \
15         ${_3dfx} \
16         ${_3dfx_linux} \
17         ${_aac} \
18         ${_aacraid} \
19         accf_data \
20         accf_dns \
21         accf_http \
22         acl_nfs4 \
23         acl_posix1e \
24         ${_acpi} \
25         ae \
26         ${_aesni} \
27         age \
28         ${_agp} \
29         aha \
30         ${_ahb} \
31         ahci \
32         ${_aic} \
33         aic7xxx \
34         aio \
35         alc \
36         ale \
37         alq \
38         ${_amdsbwd} \
39         ${_amdtemp} \
40         amr \
41         ${_an} \
42         ${_aout} \
43         ${_apm} \
44         ${_arcmsr} \
45         ${_arcnet} \
46         ${_asmc} \
47         ${_asr} \
48         ata \
49         ath \
50         ath_pci \
51         autofs \
52         ${_auxio} \
53         ${_bce} \
54         bfe \
55         bge \
56         ${_bxe} \
57         ${_bios} \
58         ${_bktr} \
59         ${_bm} \
60         bridgestp \
61         bwi \
62         bwn \
63         cam \
64         ${_canbepm} \
65         ${_canbus} \
66         ${_cardbus} \
67         ${_carp} \
68         cas \
69         ${_cbb} \
70         cc \
71         cd9660 \
72         cd9660_iconv \
73         ${_ce} \
74         ${_cfi} \
75         ${_ciss} \
76         ${_cm} \
77         ${_cmx} \
78         ${_coff} \
79         ${_coretemp} \
80         ${_cp} \
81         ${_cpsw} \
82         ${_cpuctl} \
83         ${_cpufreq} \
84         ${_crypto} \
85         ${_cryptodev} \
86         ${_cs} \
87         ${_ct} \
88         ${_ctau} \
89         ctl \
90         cuse \
91         ${_cxgb} \
92         ${_cxgbe} \
93         ${_cyclic} \
94         dc \
95         dcons \
96         dcons_crom \
97         de \
98         ${_dpms} \
99         ${_dpt} \
100         ${_drm} \
101         ${_drm2} \
102         ${_dtrace} \
103         dummynet \
104         ${_ed} \
105         ${_elink} \
106         ${_em} \
107         en \
108         ${_ep} \
109         ${_epic} \
110         esp \
111         ${_et} \
112         ${_ex} \
113         ${_exca} \
114         ${_ext2fs} \
115         ${_fatm} \
116         fdc \
117         fdescfs \
118         ${_fe} \
119         ${_filemon} \
120         firewire \
121         firmware \
122         fuse \
123         ${_fxp} \
124         gem \
125         geom \
126         ${_glxiic} \
127         ${_glxsb} \
128         hatm \
129         hifn \
130         hme \
131         ${_hpt27xx} \
132         ${_hptiop} \
133         ${_hptmv} \
134         ${_hptnr} \
135         ${_hptrr} \
136         hwpmc \
137         ${_hyperv} \
138         ${_i2c} \
139         ${_ibcore} \
140         ${_ibcs2} \
141         ${_ichwd} \
142         ${_ida} \
143         ${_ie} \
144         if_bridge \
145         if_disc \
146         if_edsc \
147         if_epair \
148         if_faith \
149         if_gif \
150         ${_if_gre} \
151         if_lagg \
152         ${_if_ndis} \
153         if_stf \
154         if_tap \
155         if_tun \
156         if_vlan \
157         ${_igb} \
158         ${_iir} \
159         imgact_binmisc \
160         ${_io} \
161         ${_ipoib} \
162         ${_ipdivert} \
163         ${_ipfilter} \
164         ${_ipfw} \
165         ipfw_nat \
166         ${_ipmi} \
167         ip6_mroute_mod \
168         ip_mroute_mod \
169         ${_ips} \
170         ${_ipw} \
171         ${_ipwfw} \
172         ${_isci} \
173         iscsi \
174         iscsi_initiator \
175         isp \
176         ${_ispfw} \
177         ${_iwi} \
178         ${_iwifw} \
179         ${_iwn} \
180         ${_iwnfw} \
181         ${_ixgb} \
182         ${_ixgbe} \
183         ${_ixl} \
184         ${_ixlv} \
185         jme \
186         joy \
187         kbdmux \
188         kgssapi \
189         kgssapi_krb5 \
190         khelp \
191         krpc \
192         ksyms \
193         le \
194         lge \
195         libalias \
196         libiconv \
197         libmbpool \
198         libmchain \
199         ${_linprocfs} \
200         ${_linsysfs} \
201         ${_linux} \
202         lmc \
203         lpt \
204         mac_biba \
205         mac_bsdextended \
206         mac_ifoff \
207         mac_lomac \
208         mac_mls \
209         mac_none \
210         mac_partition \
211         mac_portacl \
212         mac_seeotheruids \
213         mac_stub \
214         mac_test \
215         malo \
216         mcd \
217         md \
218         mem \
219         mfi \
220         mii \
221         mlx \
222         ${_mlx4} \
223         ${_mlx4ib} \
224         ${_mlxen} \
225         ${_mly} \
226         mmc \
227         mmcsd \
228         mpr \
229         mps \
230         mpt \
231         mqueue \
232         mrsas \
233         msdosfs \
234         msdosfs_iconv \
235         ${_mse} \
236         msk \
237         ${_mthca} \
238         mvs \
239         mwl \
240         ${_mwlfw} \
241         mxge \
242         my \
243         ${_nandfs} \
244         ${_nandsim} \
245         ${_ncr} \
246         ${_ncv} \
247         ${_ndis} \
248         netfpga10g \
249         ${_netgraph} \
250         ${_nfe} \
251         nfs_common \
252         nfscl \
253         nfsclient \
254         nfscommon \
255         nfsd \
256         nfslock \
257         nfslockd \
258         nfsserver \
259         nfssvc \
260         nge \
261         nmdm \
262         ${_nsp} \
263         nullfs \
264         ${_ntb} \
265         ${_nvd} \
266         ${_nvme} \
267         ${_nvram} \
268         ${_nxge} \
269         ${_opensolaris} \
270         oce \
271         ${_padlock} \
272         patm \
273         ${_pccard} \
274         ${_pcfclock} \
275         pcn \
276         ${_pf} \
277         ${_pflog} \
278         ${_pfsync} \
279         plip \
280         ${_pmc} \
281         ppbus \
282         ppc \
283         ppi \
284         pps \
285         procfs \
286         proto \
287         pseudofs \
288         ${_pst} \
289         pty  \
290         puc \
291         ${_qlxge} \
292         ${_qlxgb} \
293         ${_qlxgbe} \
294         ral \
295         ${_ralfw} \
296         ${_random} \
297         rc4 \
298         ${_rdma} \
299         re \
300         reiserfs \
301         rl \
302         ${_s3} \
303         ${_safe} \
304         ${_sbni} \
305         scc \
306         scd \
307         ${_scsi_low} \
308         sdhci \
309         sdhci_pci \
310         sem \
311         send \
312         ${_sf} \
313         ${_sfxge} \
314         sge \
315         ${_si} \
316         siba_bwn \
317         siftr \
318         siis \
319         sis \
320         sk \
321         ${_smbfs} \
322         ${_sn} \
323         ${_snc} \
324         snp \
325         ${_sound} \
326         ${_speaker} \
327         ${_splash} \
328         ${_sppp} \
329         ste \
330         ${_stg} \
331         stge \
332         ${_streams} \
333         ${_svr4} \
334         ${_sym} \
335         ${_syscons} \
336         sysvipc \
337         ${_ti} \
338         tl \
339         tmpfs \
340         ${_toecore} \
341         ${_tpm} \
342         trm \
343         ${_twa} \
344         twe \
345         tws \
346         tx \
347         ${_txp} \
348         uart \
349         ubsec \
350         udf \
351         udf_iconv \
352         ufs \
353         unionfs \
354         usb \
355         utopia \
356         ${_vesa} \
357         ${_virtio} \
358         vge \
359         ${_viawd} \
360         vkbd \
361         ${_vmm} \
362         ${_vmware} \
363         ${_vpo} \
364         vr \
365         vte \
366         vx \
367         ${_vxge} \
368         wb \
369         ${_wbwd} \
370         ${_wds} \
371         ${_wi} \
372         ${_wl} \
373         wlan \
374         wlan_acl \
375         wlan_amrr \
376         wlan_ccmp \
377         wlan_rssadapt \
378         wlan_tkip \
379         wlan_wep \
380         wlan_xauth \
381         ${_wpi} \
382         ${_wpifw} \
383         ${_x86bios} \
384         ${_xe} \
385         xl \
386         ${_zfs} \
387         zlib
388
389 .if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
390 .if exists(${.CURDIR}/../opencrypto)
391 _crypto=        crypto
392 _cryptodev=     cryptodev
393 .endif
394 .if exists(${.CURDIR}/../crypto)
395 _random=        random
396 .endif
397 .endif
398
399 .if (${MK_INET_SUPPORT} != "no" || ${MK_INET6_SUPPORT} != "no") || \
400         defined(ALL_MODULES)
401 _carp=          carp
402 _toecore=       toecore
403 .endif
404
405 .if ${MK_INET_SUPPORT} != "no" || defined(ALL_MODULES)
406 _if_gre=        if_gre
407 _ipdivert=      ipdivert
408 _ipfw=          ipfw
409 .endif
410
411 .if ${MK_IPFILTER} != "no" || defined(ALL_MODULES)
412 _ipfilter=      ipfilter
413 .endif
414
415 .if ${MK_NAND} != "no" || defined(ALL_MODULES)
416 _nandfs=        nandfs
417 _nandsim=       nandsim
418 .endif
419
420 .if ${MK_NETGRAPH} != "no" || defined(ALL_MODULES)
421 _netgraph=      netgraph
422 .endif
423
424 .if (${MK_PF} != "no" && (${MK_INET_SUPPORT} != "no" || \
425         ${MK_INET6_SUPPORT} != "no")) || defined(ALL_MODULES)
426 _pf=            pf
427 _pflog=         pflog
428 .if ${MK_INET_SUPPORT} != "no"
429 _pfsync=        pfsync
430 .endif
431 .endif
432
433 .if ${MK_SOURCELESS_UCODE} != "no"
434 _bce=           bce
435 _cxgbe=         cxgbe
436 _fatm=          fatm
437 _fxp=           fxp
438 _ispfw=         ispfw
439 _mwlfw=         mwlfw
440 _ralfw=         ralfw
441 _sf=            sf
442 _sn=            sn
443 _ti=            ti
444 _txp=           txp
445 .endif
446
447
448 .if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" && \
449         ${MACHINE_CPUARCH} != "powerpc"
450 _syscons=       syscons
451 _vpo=           vpo
452 .endif
453
454 .if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips"
455 # no BUS_SPACE_UNSPECIFIED
456 # No barrier instruction support (specific to this driver)
457 _sym=           sym
458 # intr_disable() is a macro, causes problems
459 .if ${MK_SOURCELESS_UCODE} != "no"
460 _cxgb=          cxgb
461 .endif
462 .endif
463
464 .if ${MACHINE_CPUARCH} == "i386" || ${MACHINE_CPUARCH} == "amd64"
465 _agp=           agp
466 _an=            an
467 _aout=          aout
468 _bktr=          bktr
469 _bxe=           bxe
470 _cardbus=       cardbus
471 _cbb=           cbb
472 _cpuctl=        cpuctl
473 _cpufreq=       cpufreq
474 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
475 _cyclic=        cyclic
476 .endif
477 _dpms=          dpms
478 _drm=           drm
479 _drm2=          drm2
480 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
481 _dtrace=        dtrace
482 .endif
483 _ed=            ed
484 _em=            em
485 _et=            et
486 _exca=          exca
487 _ext2fs=        ext2fs
488 _filemon=       filemon
489 _i2c=           i2c
490 .if ${MK_OFED} != "no" || defined(ALL_MODULES)
491 _ibcore=        ibcore
492 .endif
493 _if_ndis=       if_ndis
494 _igb=           igb
495 _io=            io
496 .if ${MK_OFED} != "no" || defined(ALL_MODULES)
497 _ipoib=         ipoib
498 .endif
499 _linprocfs=     linprocfs
500 _linsysfs=      linsysfs
501 _linux=         linux
502 _ndis=          ndis
503 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
504 _opensolaris=   opensolaris
505 .endif
506 _pccard=        pccard
507 .if ${MK_OFED} != "no" || defined(ALL_MODULES)
508 _rdma=          rdma
509 .endif
510 _safe=          safe
511 _scsi_low=      scsi_low
512 _si=            si
513 _smbfs=         smbfs
514 _sound=         sound
515 _speaker=       speaker
516 _splash=        splash
517 _sppp=          sppp
518 _vmware=        vmware
519 _vxge=          vxge
520 _wbwd=          wbwd
521 _wi=            wi
522 .if ${MK_ZFS} != "no" || defined(ALL_MODULES)
523 _zfs=           zfs
524 .endif
525 .if ${MACHINE} != "pc98"
526 _aac=           aac
527 _aacraid=       aacraid
528 _acpi=          acpi
529 .if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
530 _aesni=         aesni
531 .endif
532 _amdsbwd=       amdsbwd
533 _amdtemp=       amdtemp
534 _arcmsr=        arcmsr
535 _asmc=          asmc
536 _ciss=          ciss
537 _cmx=           cmx
538 _coretemp=      coretemp
539 .if ${MK_SOURCELESS_HOST} != "no"
540 _hpt27xx=       hpt27xx
541 .endif
542 _hptiop=        hptiop
543 .if ${MK_SOURCELESS_HOST} != "no"
544 _hptmv=         hptmv
545 _hptnr=         hptnr
546 _hptrr=         hptrr
547 .endif
548 _hyperv=        hyperv
549 _ichwd=         ichwd
550 _ida=           ida
551 _iir=           iir
552 _ipmi=          ipmi
553 _ips=           ips
554 _ipw=           ipw
555 .if ${MK_SOURCELESS_UCODE} != "no"
556 _ipwfw=         ipwfw
557 .endif
558 _isci=          isci
559 _iwi=           iwi
560 .if ${MK_SOURCELESS_UCODE} != "no"
561 _iwifw=         iwifw
562 .endif
563 _iwn=           iwn
564 .if ${MK_SOURCELESS_UCODE} != "no"
565 _iwnfw=         iwnfw
566 .endif
567 _ixgb=          ixgb
568 _ixgbe=         ixgbe
569 .if ${MK_OFED} != "no" || defined(ALL_MODULES)
570 _mlx4=          mlx4
571 _mlx4ib=        mlx4ib
572 _mlxen=         mlxen
573 .endif
574 _mly=           mly
575 .if ${MK_OFED} != "no" || defined(ALL_MODULES)
576 _mthca=         mthca
577 .endif
578 _nfe=           nfe
579 _nvd=           nvd
580 _nvme=          nvme
581 _nvram=         nvram
582 _nxge=          nxge
583 .if ${MK_CRYPT} != "no" || defined(ALL_MODULES)
584 _padlock=       padlock
585 .endif
586 _s3=            s3
587 _tpm=           tpm
588 _twa=           twa
589 _vesa=          vesa
590 _viawd=         viawd
591 _virtio=        virtio
592 _wpi=           wpi
593 .if ${MK_SOURCELESS_UCODE} != "no"
594 _wpifw=         wpifw
595 .endif
596 _x86bios=       x86bios
597 .endif
598 .endif
599
600 .if ${MACHINE_CPUARCH} == "amd64"
601 _ixl=           ixl
602 _ixlv=          ixlv
603 _ntb=           ntb
604 _qlxge=         qlxge
605 _qlxgb=         qlxgb
606 _qlxgbe=        qlxgbe
607 _sfxge=         sfxge
608 _vmm=           vmm
609 .endif
610
611 .if ${MACHINE_CPUARCH} == "i386"
612 # XXX some of these can move to the general case when de-i386'ed
613 # XXX some of these can move now, but are untested on other architectures.
614 _3dfx=          3dfx
615 _3dfx_linux=    3dfx_linux
616 _aic=           aic
617 _apm=           apm
618 _arcnet=        arcnet
619 .if ${MK_SOURCELESS_UCODE} != "no"
620 _ce=            ce
621 .endif
622 _coff=          coff
623 .if ${MK_SOURCELESS_UCODE} != "no"
624 _cp=            cp
625 .endif
626 _cs=            cs
627 _elink=         elink
628 _ep=            ep
629 _fe=            fe
630 _glxiic=        glxiic
631 _glxsb=         glxsb
632 _ibcs2=         ibcs2
633 _ie=            ie
634 _mse=           mse
635 _ncr=           ncr
636 _ncv=           ncv
637 _nsp=           nsp
638 _pcfclock=      pcfclock
639 _pst=           pst
640 _sbni=          sbni
641 _streams=       streams
642 _stg=           stg
643 _svr4=          svr4
644 _wds=           wds
645 _xe=            xe
646 .if ${MACHINE} == "i386"
647 .if ${MK_EISA} != "no"
648 _ahb=           ahb
649 .endif
650 _asr=           asr
651 _bios=          bios
652 _cm=            cm
653 .if ${MK_SOURCELESS_UCODE} != "no"
654 _ctau=          ctau
655 .endif
656 _dpt=           dpt
657 _ex=            ex
658 _wl=            wl
659 .elif ${MACHINE} == "pc98"
660 _canbepm=       canbepm
661 _canbus=        canbus
662 _ct=            ct
663 _pmc=           pmc
664 _snc=           snc
665 .endif
666 .endif
667
668 .if ${MACHINE_CPUARCH} == "arm"
669 _cfi=           cfi
670 _cpsw=          cpsw
671 _sound=         sound
672 .endif
673
674 .if ${MACHINE_CPUARCH} == "powerpc"
675 _agp=           agp
676 _an=            an
677 _bm=            bm
678 _cardbus=       cardbus
679 _cbb=           cbb
680 _cfi=           cfi
681 _cpufreq=       cpufreq
682 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
683 _cyclic=        cyclic
684 .endif
685 _drm=           drm
686 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
687 _dtrace=        dtrace
688 .endif
689 _exca=          exca
690 _nvram=         powermac_nvram
691 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
692 _opensolaris=   opensolaris
693 .endif
694 _pccard=        pccard
695 _smbfs=         smbfs
696 _sound=         sound
697 _wi=            wi
698 .endif
699
700 .if ${MACHINE_ARCH} == "powerpc64"
701 .if ${MK_ZFS} != "no" || defined(ALL_MODULES)
702 _zfs=           zfs
703 .endif
704 .endif
705
706 .if ${MACHINE_CPUARCH} == "sparc64"
707 _auxio=         auxio
708 _em=            em
709 _epic=          epic
710 _i2c=           i2c
711 _igb=           igb
712 .if ${MK_CDDL} != "no" || defined(ALL_MODULES)
713 _opensolaris=   opensolaris
714 .endif
715 _smbfs=         smbfs
716 _sound=         sound
717 .if ${MK_ZFS} != "no" || defined(ALL_MODULES)
718 _zfs=           zfs
719 .endif
720 .endif
721
722 .endif
723
724 .for reject in ${WITHOUT_MODULES}
725 SUBDIR:= ${SUBDIR:N${reject}}
726 .endfor
727
728 # Calling kldxref(8) for each module is expensive.
729 .if !defined(NO_XREF)
730 .MAKEFLAGS+=    -DNO_XREF
731 afterinstall:
732         @if type kldxref >/dev/null 2>&1; then \
733                 ${ECHO} kldxref ${DESTDIR}${KMODDIR}; \
734                 kldxref ${DESTDIR}${KMODDIR}; \
735         fi
736 .endif
737
738 .include <bsd.subdir.mk>