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