1# $FreeBSD$ 2# 3# The include file <src.libnames.mk> define library names suitable 4# for INTERNALLIB and PRIVATELIB definition 5 6.if !target(__<bsd.init.mk>__) 7.error src.libnames.mk cannot be included directly. 8.endif 9 10.if !target(__<src.libnames.mk>__) 11__<src.libnames.mk>__: 12 13.include <src.opts.mk> 14 15_PRIVATELIBS= \ 16 atf_c \ 17 atf_cxx \ 18 auditd \ 19 bsdstat \ 20 devdctl \ 21 event1 \ 22 gmock \ 23 gtest \ 24 gmock_main \ 25 gtest_main \ 26 heimipcc \ 27 heimipcs \ 28 ldns \ 29 sqlite3 \ 30 ssh \ 31 ucl \ 32 unbound \ 33 zstd 34 35_INTERNALLIBS= \ 36 amu \ 37 bsnmptools \ 38 c_nossp_pic \ 39 cron \ 40 elftc \ 41 fifolog \ 42 ifconfig \ 43 ipf \ 44 kyua_cli \ 45 kyua_drivers \ 46 kyua_engine \ 47 kyua_model \ 48 kyua_store \ 49 kyua_utils \ 50 lpr \ 51 lua \ 52 lutok \ 53 netbsd \ 54 ntp \ 55 ntpevent \ 56 openbsd \ 57 opts \ 58 parse \ 59 pe \ 60 pmcstat \ 61 sl \ 62 sm \ 63 smdb \ 64 smutil \ 65 telnet \ 66 vers 67 68_LIBRARIES= \ 69 ${_PRIVATELIBS} \ 70 ${_INTERNALLIBS} \ 71 ${LOCAL_LIBRARIES} \ 72 80211 \ 73 alias \ 74 archive \ 75 asn1 \ 76 avl \ 77 be \ 78 begemot \ 79 bluetooth \ 80 bsdxml \ 81 bsm \ 82 bsnmp \ 83 bz2 \ 84 c \ 85 c_pic \ 86 calendar \ 87 cam \ 88 casper \ 89 cap_dns \ 90 cap_fileargs \ 91 cap_grp \ 92 cap_pwd \ 93 cap_sysctl \ 94 cap_syslog \ 95 com_err \ 96 compiler_rt \ 97 crypt \ 98 crypto \ 99 ctf \ 100 cuse \ 101 cxxrt \ 102 devctl \ 103 devdctl \ 104 devinfo \ 105 devstat \ 106 dialog \ 107 dl \ 108 dpv \ 109 dtrace \ 110 dwarf \ 111 edit \ 112 efivar \ 113 elf \ 114 execinfo \ 115 fetch \ 116 figpar \ 117 geom \ 118 gnuregex \ 119 gpio \ 120 gssapi \ 121 gssapi_krb5 \ 122 hdb \ 123 heimbase \ 124 heimntlm \ 125 heimsqlite \ 126 hx509 \ 127 ipsec \ 128 ipt \ 129 jail \ 130 kadm5clnt \ 131 kadm5srv \ 132 kafs5 \ 133 kdc \ 134 kiconv \ 135 krb5 \ 136 kvm \ 137 l \ 138 lzma \ 139 m \ 140 magic \ 141 md \ 142 memstat \ 143 mp \ 144 mt \ 145 ncurses \ 146 ncursesw \ 147 netgraph \ 148 ngatm \ 149 nv \ 150 nvpair \ 151 opencsd \ 152 opie \ 153 pam \ 154 panel \ 155 panelw \ 156 pcap \ 157 pcsclite \ 158 pjdlog \ 159 pmc \ 160 proc \ 161 procstat \ 162 pthread \ 163 radius \ 164 regex \ 165 roken \ 166 rpcsec_gss \ 167 rpcsvc \ 168 rt \ 169 rtld_db \ 170 sbuf \ 171 sdp \ 172 sm \ 173 smb \ 174 ssl \ 175 ssp_nonshared \ 176 stats \ 177 stdthreads \ 178 supcplusplus \ 179 sysdecode \ 180 tacplus \ 181 termcap \ 182 termcapw \ 183 ufs \ 184 ugidfw \ 185 ulog \ 186 umem \ 187 usb \ 188 usbhid \ 189 util \ 190 uutil \ 191 vmmapi \ 192 wind \ 193 wrap \ 194 xo \ 195 y \ 196 ypclnt \ 197 z \ 198 zfs_core \ 199 zfs \ 200 zpool \ 201 202.if ${MK_BLACKLIST} != "no" 203_LIBRARIES+= \ 204 blacklist \ 205 206.endif 207 208.if ${MK_OFED} != "no" 209_LIBRARIES+= \ 210 cxgb4 \ 211 ibcm \ 212 ibmad \ 213 ibnetdisc \ 214 ibumad \ 215 ibverbs \ 216 mlx4 \ 217 mlx5 \ 218 rdmacm \ 219 osmcomp \ 220 opensm \ 221 osmvendor 222.endif 223 224.if ${MK_BEARSSL} == "yes" 225_LIBRARIES+= \ 226 bearssl \ 227 secureboot \ 228 229LIBBEARSSL?= ${LIBBEARSSLDIR}/libbearssl.a 230LIBSECUREBOOT?= ${LIBSECUREBOOTDIR}/libsecureboot.a 231.endif 232 233.if ${MK_VERIEXEC} == "yes" 234_LIBRARIES+= veriexec 235 236LIBVERIEXEC?= ${LIBVERIEXECDIR}/libveriexec.a 237.endif 238 239# Each library's LIBADD needs to be duplicated here for static linkage of 240# 2nd+ order consumers. Auto-generating this would be better. 241_DP_80211= sbuf bsdxml 242_DP_archive= z bz2 lzma bsdxml zstd 243_DP_zstd= pthread 244.if ${MK_BLACKLIST} != "no" 245_DP_blacklist+= pthread 246.endif 247_DP_crypto= pthread 248.if ${MK_OPENSSL} != "no" 249_DP_archive+= crypto 250.else 251_DP_archive+= md 252.endif 253_DP_sqlite3= pthread 254_DP_ssl= crypto 255_DP_ssh= crypto crypt z 256.if ${MK_LDNS} != "no" 257_DP_ssh+= ldns 258.endif 259_DP_edit= ncursesw 260.if ${MK_OPENSSL} != "no" 261_DP_bsnmp= crypto 262.endif 263_DP_geom= bsdxml sbuf 264_DP_cam= sbuf 265_DP_kvm= elf 266_DP_kyua_cli= kyua_drivers kyua_engine kyua_model kyua_store kyua_utils 267_DP_kyua_drivers= kyua_model kyua_engine kyua_store 268_DP_kyua_engine= lutok kyua_utils 269_DP_kyua_model= lutok 270_DP_kyua_utils= lutok 271_DP_kyua_store= kyua_model kyua_utils sqlite3 272_DP_casper= nv 273_DP_cap_dns= nv 274_DP_cap_fileargs= nv 275_DP_cap_grp= nv 276_DP_cap_pwd= nv 277_DP_cap_sysctl= nv 278_DP_cap_syslog= nv 279.if ${MK_OFED} != "no" 280_DP_pcap= ibverbs mlx5 281.endif 282_DP_pjdlog= util 283_DP_opie= md 284_DP_usb= pthread 285_DP_unbound= ssl crypto pthread 286_DP_rt= pthread 287.if ${MK_OPENSSL} == "no" 288_DP_radius= md 289.else 290_DP_radius= crypto 291.endif 292_DP_rtld_db= elf procstat 293_DP_procstat= kvm util elf 294.if ${MK_CXX} == "yes" 295.if ${MK_LIBCPLUSPLUS} != "no" 296_DP_proc= cxxrt 297.else 298_DP_proc= supcplusplus 299.endif 300.endif 301.if ${MK_CDDL} != "no" 302_DP_proc+= ctf 303.endif 304_DP_proc+= elf procstat rtld_db util 305_DP_mp= crypto 306_DP_memstat= kvm 307_DP_magic= z 308_DP_mt= sbuf bsdxml 309_DP_ldns= ssl crypto 310_DP_lua= m 311_DP_lutok= lua 312.if ${MK_OPENSSL} != "no" 313_DP_fetch= ssl crypto 314.else 315_DP_fetch= md 316.endif 317_DP_execinfo= elf 318_DP_dwarf= elf 319_DP_dpv= dialog figpar util ncursesw 320_DP_dialog= ncursesw m 321_DP_cuse= pthread 322_DP_atf_cxx= atf_c 323_DP_gtest= pthread regex 324_DP_gmock= gtest 325_DP_gmock_main= gmock 326_DP_gtest_main= gtest 327_DP_devstat= kvm 328_DP_pam= radius tacplus opie md util 329.if ${MK_KERBEROS} != "no" 330_DP_pam+= krb5 331.endif 332.if ${MK_OPENSSH} != "no" 333_DP_pam+= ssh 334.endif 335.if ${MK_NIS} != "no" 336_DP_pam+= ypclnt 337.endif 338_DP_roken= crypt 339_DP_kadm5clnt= com_err krb5 roken 340_DP_kadm5srv= com_err hdb krb5 roken 341_DP_heimntlm= crypto com_err krb5 roken 342_DP_hx509= asn1 com_err crypto roken wind 343_DP_hdb= asn1 com_err krb5 roken sqlite3 344_DP_asn1= com_err roken 345_DP_kdc= roken hdb hx509 krb5 heimntlm asn1 crypto 346_DP_wind= com_err roken 347_DP_heimbase= pthread 348_DP_heimipcc= heimbase roken pthread 349_DP_heimipcs= heimbase roken pthread 350_DP_kafs5= asn1 krb5 roken 351_DP_krb5+= asn1 com_err crypt crypto hx509 roken wind heimbase heimipcc 352_DP_gssapi_krb5+= gssapi krb5 crypto roken asn1 com_err 353_DP_lzma= md pthread 354_DP_ucl= m 355_DP_vmmapi= util 356_DP_opencsd= cxxrt 357_DP_ctf= z 358_DP_dtrace= ctf elf proc pthread rtld_db 359_DP_xo= util 360# The libc dependencies are not strictly needed but are defined to make the 361# assert happy. 362_DP_c= compiler_rt 363.if ${MK_SSP} != "no" && \ 364 (${MACHINE_ARCH} == "i386" || ${MACHINE_ARCH:Mpower*} != "") 365_DP_c+= ssp_nonshared 366.endif 367_DP_stats= sbuf pthread 368_DP_stdthreads= pthread 369_DP_tacplus= md 370_DP_panel= ncurses 371_DP_panelw= ncursesw 372_DP_rpcsec_gss= gssapi 373_DP_smb= kiconv 374_DP_ulog= md 375_DP_fifolog= z 376_DP_ipf= kvm 377_DP_zfs= md pthread umem util uutil m nvpair avl bsdxml geom nvpair z \ 378 zfs_core 379_DP_zfs_core= nvpair 380_DP_zpool= md pthread z nvpair avl umem 381_DP_be= zfs nvpair 382 383# OFED support 384.if ${MK_OFED} != "no" 385_DP_cxgb4= ibverbs pthread 386_DP_ibcm= ibverbs 387_DP_ibmad= ibumad 388_DP_ibnetdisc= osmcomp ibmad ibumad 389_DP_ibumad= 390_DP_ibverbs= 391_DP_mlx4= ibverbs pthread 392_DP_mlx5= ibverbs pthread 393_DP_rdmacm= ibverbs 394_DP_osmcomp= pthread 395_DP_opensm= pthread 396_DP_osmvendor= ibumad pthread 397.endif 398 399# Define special cases 400LDADD_supcplusplus= -lsupc++ 401LIBATF_C= ${LIBDESTDIR}${LIBDIR_BASE}/libprivateatf-c.a 402LIBATF_CXX= ${LIBDESTDIR}${LIBDIR_BASE}/libprivateatf-c++.a 403LDADD_atf_c= -lprivateatf-c 404LDADD_atf_cxx= -lprivateatf-c++ 405 406LIBGMOCK= ${LIBDESTDIR}${LIBDIR_BASE}/libprivategmock.a 407LIBGMOCK_MAIN= ${LIBDESTDIR}${LIBDIR_BASE}/libprivategmock_main.a 408LIBGTEST= ${LIBDESTDIR}${LIBDIR_BASE}/libprivategtest.a 409LIBGTEST_MAIN= ${LIBDESTDIR}${LIBDIR_BASE}/libprivategtest_main.a 410LDADD_gmock= -lprivategmock 411LDADD_gtest= -lprivategtest 412LDADD_gmock_main= -lprivategmock_main 413LDADD_gtest_main= -lprivategtest_main 414 415.for _l in ${_PRIVATELIBS} 416LIB${_l:tu}?= ${LIBDESTDIR}${LIBDIR_BASE}/libprivate${_l}.a 417.endfor 418 419.if ${MK_PIE} != "no" 420PIE_SUFFIX= _pie 421.endif 422 423.for _l in ${_LIBRARIES} 424.if ${_INTERNALLIBS:M${_l}} || !defined(SYSROOT) 425LDADD_${_l}_L+= -L${LIB${_l:tu}DIR} 426.endif 427DPADD_${_l}?= ${LIB${_l:tu}} 428.if ${_PRIVATELIBS:M${_l}} 429LDADD_${_l}?= -lprivate${_l} 430.elif ${_INTERNALLIBS:M${_l}} 431LDADD_${_l}?= ${LDADD_${_l}_L} -l${_l:S/${PIE_SUFFIX}//}${PIE_SUFFIX} 432.else 433LDADD_${_l}?= ${LDADD_${_l}_L} -l${_l} 434.endif 435# Add in all dependencies for static linkage. 436.if defined(_DP_${_l}) && (${_INTERNALLIBS:M${_l}} || \ 437 (defined(NO_SHARED) && ${NO_SHARED:tl} != "no")) 438.for _d in ${_DP_${_l}} 439DPADD_${_l}+= ${DPADD_${_d}} 440LDADD_${_l}+= ${LDADD_${_d}} 441.endfor 442.endif 443.endfor 444 445# These are special cases where the library is broken and anything that uses 446# it needs to add more dependencies. Broken usually means that it has a 447# cyclic dependency and cannot link its own dependencies. This is bad, please 448# fix the library instead. 449# Unless the library itself is broken then the proper place to define 450# dependencies is _DP_* above. 451 452# libatf-c++ exposes libatf-c abi hence we need to explicit link to atf_c for 453# atf_cxx 454DPADD_atf_cxx+= ${DPADD_atf_c} 455LDADD_atf_cxx+= ${LDADD_atf_c} 456 457DPADD_gmock+= ${DPADD_gtest} 458LDADD_gmock+= ${LDADD_gtest} 459 460DPADD_gmock_main+= ${DPADD_gmock} 461LDADD_gmock_main+= ${LDADD_gmock} 462 463DPADD_gtest_main+= ${DPADD_gtest} 464LDADD_gtest_main+= ${LDADD_gtest} 465 466# Detect LDADD/DPADD that should be LIBADD, before modifying LDADD here. 467_BADLDADD= 468.for _l in ${LDADD:M-l*:N-l*/*:C,^-l,,} 469.if ${_LIBRARIES:M${_l}} && !${_PRIVATELIBS:M${_l}} 470_BADLDADD+= ${_l} 471.endif 472.endfor 473.if !empty(_BADLDADD) 474.error ${.CURDIR}: These libraries should be LIBADD+=foo rather than DPADD/LDADD+=-lfoo: ${_BADLDADD} 475.endif 476 477.for _l in ${LIBADD} 478DPADD+= ${DPADD_${_l}} 479LDADD+= ${LDADD_${_l}} 480.endfor 481 482_LIB_OBJTOP?= ${OBJTOP} 483# INTERNALLIB definitions. 484LIBELFTCDIR= ${_LIB_OBJTOP}/lib/libelftc 485LIBELFTC?= ${LIBELFTCDIR}/libelftc${PIE_SUFFIX}.a 486 487LIBKYUA_CLIDIR= ${_LIB_OBJTOP}/lib/kyua/cli 488LIBKYUA_CLI?= ${LIBKYUA_CLIDIR}/libkyua_cli${PIE_SUFFIX}.a 489 490LIBKYUA_DRIVERSDIR= ${_LIB_OBJTOP}/lib/kyua/drivers 491LIBKYUA_DRIVERS?= ${LIBKYUA_DRIVERSDIR}/libkyua_drivers${PIE_SUFFIX}.a 492 493LIBKYUA_ENGINEDIR= ${_LIB_OBJTOP}/lib/kyua/engine 494LIBKYUA_ENGINE?= ${LIBKYUA_ENGINEDIR}/libkyua_engine${PIE_SUFFIX}.a 495 496LIBKYUA_MODELDIR= ${_LIB_OBJTOP}/lib/kyua/model 497LIBKYUA_MODEL?= ${LIBKYUA_MODELDIR}/libkyua_model${PIE_SUFFIX}.a 498 499LIBKYUA_STOREDIR= ${_LIB_OBJTOP}/lib/kyua/store 500LIBKYUA_STORE?= ${LIBKYUA_STOREDIR}/libkyua_store${PIE_SUFFIX}.a 501 502LIBKYUA_UTILSDIR= ${_LIB_OBJTOP}/lib/kyua/utils 503LIBKYUA_UTILS?= ${LIBKYUA_UTILSDIR}/libkyua_utils${PIE_SUFFIX}.a 504 505LIBLUADIR= ${_LIB_OBJTOP}/lib/liblua 506LIBLUA?= ${LIBLUADIR}/liblua${PIE_SUFFIX}.a 507 508LIBLUTOKDIR= ${_LIB_OBJTOP}/lib/liblutok 509LIBLUTOK?= ${LIBLUTOKDIR}/liblutok${PIE_SUFFIX}.a 510 511LIBPEDIR= ${_LIB_OBJTOP}/lib/libpe 512LIBPE?= ${LIBPEDIR}/libpe${PIE_SUFFIX}.a 513 514LIBOPENBSDDIR= ${_LIB_OBJTOP}/lib/libopenbsd 515LIBOPENBSD?= ${LIBOPENBSDDIR}/libopenbsd${PIE_SUFFIX}.a 516 517LIBSMDIR= ${_LIB_OBJTOP}/lib/libsm 518LIBSM?= ${LIBSMDIR}/libsm${PIE_SUFFIX}.a 519 520LIBSMDBDIR= ${_LIB_OBJTOP}/lib/libsmdb 521LIBSMDB?= ${LIBSMDBDIR}/libsmdb${PIE_SUFFIX}.a 522 523LIBSMUTILDIR= ${_LIB_OBJTOP}/lib/libsmutil 524LIBSMUTIL?= ${LIBSMUTILDIR}/libsmutil${PIE_SUFFIX}.a 525 526LIBNETBSDDIR?= ${_LIB_OBJTOP}/lib/libnetbsd 527LIBNETBSD?= ${LIBNETBSDDIR}/libnetbsd${PIE_SUFFIX}.a 528 529LIBVERSDIR?= ${_LIB_OBJTOP}/kerberos5/lib/libvers 530LIBVERS?= ${LIBVERSDIR}/libvers${PIE_SUFFIX}.a 531 532LIBSLDIR= ${_LIB_OBJTOP}/kerberos5/lib/libsl 533LIBSL?= ${LIBSLDIR}/libsl${PIE_SUFFIX}.a 534 535LIBIFCONFIGDIR= ${_LIB_OBJTOP}/lib/libifconfig 536LIBIFCONFIG?= ${LIBIFCONFIGDIR}/libifconfig${PIE_SUFFIX}.a 537 538LIBIPFDIR= ${_LIB_OBJTOP}/sbin/ipf/libipf 539LIBIPF?= ${LIBIPFDIR}/libipf${PIE_SUFFIX}.a 540 541LIBTELNETDIR= ${_LIB_OBJTOP}/lib/libtelnet 542LIBTELNET?= ${LIBTELNETDIR}/libtelnet${PIE_SUFFIX}.a 543 544LIBCRONDIR= ${_LIB_OBJTOP}/usr.sbin/cron/lib 545LIBCRON?= ${LIBCRONDIR}/libcron${PIE_SUFFIX}.a 546 547LIBNTPDIR= ${_LIB_OBJTOP}/usr.sbin/ntp/libntp 548LIBNTP?= ${LIBNTPDIR}/libntp${PIE_SUFFIX}.a 549 550LIBNTPEVENTDIR= ${_LIB_OBJTOP}/usr.sbin/ntp/libntpevent 551LIBNTPEVENT?= ${LIBNTPEVENTDIR}/libntpevent${PIE_SUFFIX}.a 552 553LIBOPTSDIR= ${_LIB_OBJTOP}/usr.sbin/ntp/libopts 554LIBOPTS?= ${LIBOPTSDIR}/libopts${PIE_SUFFIX}.a 555 556LIBPARSEDIR= ${_LIB_OBJTOP}/usr.sbin/ntp/libparse 557LIBPARSE?= ${LIBPARSEDIR}/libparse${PIE_SUFFIX}.a 558 559LIBLPRDIR= ${_LIB_OBJTOP}/usr.sbin/lpr/common_source 560LIBLPR?= ${LIBLPRDIR}/liblpr${PIE_SUFFIX}.a 561 562LIBFIFOLOGDIR= ${_LIB_OBJTOP}/usr.sbin/fifolog/lib 563LIBFIFOLOG?= ${LIBFIFOLOGDIR}/libfifolog${PIE_SUFFIX}.a 564 565LIBBSNMPTOOLSDIR= ${_LIB_OBJTOP}/usr.sbin/bsnmpd/tools/libbsnmptools 566LIBBSNMPTOOLS?= ${LIBBSNMPTOOLSDIR}/libbsnmptools${PIE_SUFFIX}.a 567 568LIBAMUDIR= ${_LIB_OBJTOP}/usr.sbin/amd/libamu 569LIBAMU?= ${LIBAMUDIR}/libamu${PIE_SUFFIX}.a 570 571LIBBE?= ${LIBBEDIR}/libbe${PIE_SUFFIX}.a 572 573LIBPMCSTATDIR= ${_LIB_OBJTOP}/lib/libpmcstat 574LIBPMCSTAT?= ${LIBPMCSTATDIR}/libpmcstat${PIE_SUFFIX}.a 575 576LIBC_NOSSP_PICDIR= ${_LIB_OBJTOP}/lib/libc 577LIBC_NOSSP_PIC?= ${LIBC_NOSSP_PICDIR}/libc_nossp_pic.a 578 579# Define a directory for each library. This is useful for adding -L in when 580# not using a --sysroot or for meta mode bootstrapping when there is no 581# Makefile.depend. These are sorted by directory. 582LIBAVLDIR= ${OBJTOP}/cddl/lib/libavl 583LIBCTFDIR= ${OBJTOP}/cddl/lib/libctf 584LIBDTRACEDIR= ${OBJTOP}/cddl/lib/libdtrace 585LIBNVPAIRDIR= ${OBJTOP}/cddl/lib/libnvpair 586LIBUMEMDIR= ${OBJTOP}/cddl/lib/libumem 587LIBUUTILDIR= ${OBJTOP}/cddl/lib/libuutil 588LIBZFSDIR= ${OBJTOP}/cddl/lib/libzfs 589LIBZFS_COREDIR= ${OBJTOP}/cddl/lib/libzfs_core 590LIBZPOOLDIR= ${OBJTOP}/cddl/lib/libzpool 591 592# OFED support 593LIBCXGB4DIR= ${OBJTOP}/lib/ofed/libcxgb4 594LIBIBCMDIR= ${OBJTOP}/lib/ofed/libibcm 595LIBIBMADDIR= ${OBJTOP}/lib/ofed/libibmad 596LIBIBNETDISCDIR=${OBJTOP}/lib/ofed/libibnetdisc 597LIBIBUMADDIR= ${OBJTOP}/lib/ofed/libibumad 598LIBIBVERBSDIR= ${OBJTOP}/lib/ofed/libibverbs 599LIBMLX4DIR= ${OBJTOP}/lib/ofed/libmlx4 600LIBMLX5DIR= ${OBJTOP}/lib/ofed/libmlx5 601LIBRDMACMDIR= ${OBJTOP}/lib/ofed/librdmacm 602LIBOSMCOMPDIR= ${OBJTOP}/lib/ofed/complib 603LIBOPENSMDIR= ${OBJTOP}/lib/ofed/libopensm 604LIBOSMVENDORDIR=${OBJTOP}/lib/ofed/libvendor 605 606LIBDIALOGDIR= ${OBJTOP}/gnu/lib/libdialog 607LIBGNUREGEXDIR= ${OBJTOP}/gnu/lib/libregex 608LIBSSPDIR= ${OBJTOP}/lib/libssp 609LIBSSP_NONSHAREDDIR= ${OBJTOP}/lib/libssp_nonshared 610LIBASN1DIR= ${OBJTOP}/kerberos5/lib/libasn1 611LIBGSSAPI_KRB5DIR= ${OBJTOP}/kerberos5/lib/libgssapi_krb5 612LIBGSSAPI_NTLMDIR= ${OBJTOP}/kerberos5/lib/libgssapi_ntlm 613LIBGSSAPI_SPNEGODIR= ${OBJTOP}/kerberos5/lib/libgssapi_spnego 614LIBHDBDIR= ${OBJTOP}/kerberos5/lib/libhdb 615LIBHEIMBASEDIR= ${OBJTOP}/kerberos5/lib/libheimbase 616LIBHEIMIPCCDIR= ${OBJTOP}/kerberos5/lib/libheimipcc 617LIBHEIMIPCSDIR= ${OBJTOP}/kerberos5/lib/libheimipcs 618LIBHEIMNTLMDIR= ${OBJTOP}/kerberos5/lib/libheimntlm 619LIBHX509DIR= ${OBJTOP}/kerberos5/lib/libhx509 620LIBKADM5CLNTDIR= ${OBJTOP}/kerberos5/lib/libkadm5clnt 621LIBKADM5SRVDIR= ${OBJTOP}/kerberos5/lib/libkadm5srv 622LIBKAFS5DIR= ${OBJTOP}/kerberos5/lib/libkafs5 623LIBKDCDIR= ${OBJTOP}/kerberos5/lib/libkdc 624LIBKRB5DIR= ${OBJTOP}/kerberos5/lib/libkrb5 625LIBROKENDIR= ${OBJTOP}/kerberos5/lib/libroken 626LIBWINDDIR= ${OBJTOP}/kerberos5/lib/libwind 627LIBATF_CDIR= ${OBJTOP}/lib/atf/libatf-c 628LIBATF_CXXDIR= ${OBJTOP}/lib/atf/libatf-c++ 629LIBGMOCKDIR= ${OBJTOP}/lib/googletest/gmock 630LIBGMOCK_MAINDIR= ${OBJTOP}/lib/googletest/gmock_main 631LIBGTESTDIR= ${OBJTOP}/lib/googletest/gtest 632LIBGTEST_MAINDIR= ${OBJTOP}/lib/googletest/gtest_main 633LIBALIASDIR= ${OBJTOP}/lib/libalias/libalias 634LIBBLACKLISTDIR= ${OBJTOP}/lib/libblacklist 635LIBBLOCKSRUNTIMEDIR= ${OBJTOP}/lib/libblocksruntime 636LIBBSNMPDIR= ${OBJTOP}/lib/libbsnmp/libbsnmp 637LIBCASPERDIR= ${OBJTOP}/lib/libcasper/libcasper 638LIBCAP_DNSDIR= ${OBJTOP}/lib/libcasper/services/cap_dns 639LIBCAP_GRPDIR= ${OBJTOP}/lib/libcasper/services/cap_grp 640LIBCAP_PWDDIR= ${OBJTOP}/lib/libcasper/services/cap_pwd 641LIBCAP_SYSCTLDIR= ${OBJTOP}/lib/libcasper/services/cap_sysctl 642LIBCAP_SYSLOGDIR= ${OBJTOP}/lib/libcasper/services/cap_syslog 643LIBBSDXMLDIR= ${OBJTOP}/lib/libexpat 644LIBKVMDIR= ${OBJTOP}/lib/libkvm 645LIBPTHREADDIR= ${OBJTOP}/lib/libthr 646LIBMDIR= ${OBJTOP}/lib/msun 647LIBFORMDIR= ${OBJTOP}/lib/ncurses/form 648LIBFORMLIBWDIR= ${OBJTOP}/lib/ncurses/formw 649LIBMENUDIR= ${OBJTOP}/lib/ncurses/menu 650LIBMENULIBWDIR= ${OBJTOP}/lib/ncurses/menuw 651LIBNCURSESDIR= ${OBJTOP}/lib/ncurses/ncurses 652LIBNCURSESWDIR= ${OBJTOP}/lib/ncurses/ncursesw 653LIBPANELDIR= ${OBJTOP}/lib/ncurses/panel 654LIBPANELWDIR= ${OBJTOP}/lib/ncurses/panelw 655LIBCRYPTODIR= ${OBJTOP}/secure/lib/libcrypto 656LIBSSHDIR= ${OBJTOP}/secure/lib/libssh 657LIBSSLDIR= ${OBJTOP}/secure/lib/libssl 658LIBTEKENDIR= ${OBJTOP}/sys/teken/libteken 659LIBEGACYDIR= ${OBJTOP}/tools/build 660LIBLNDIR= ${OBJTOP}/usr.bin/lex/lib 661 662LIBTERMCAPDIR= ${LIBNCURSESDIR} 663LIBTERMCAPWDIR= ${LIBNCURSESWDIR} 664 665# Default other library directories to lib/libNAME. 666.for lib in ${_LIBRARIES} 667LIB${lib:tu}DIR?= ${OBJTOP}/lib/lib${lib} 668.endfor 669 670# Validate that listed LIBADD are valid. 671.for _l in ${LIBADD} 672.if empty(_LIBRARIES:M${_l}) 673_BADLIBADD+= ${_l} 674.endif 675.endfor 676.if !empty(_BADLIBADD) 677.error ${.CURDIR}: Invalid LIBADD used which may need to be added to ${_this:T}: ${_BADLIBADD} 678.endif 679 680# Sanity check that libraries are defined here properly when building them. 681.if defined(LIB) && ${_LIBRARIES:M${LIB}} != "" 682.if !empty(LIBADD) && \ 683 (!defined(_DP_${LIB}) || ${LIBADD:O:u} != ${_DP_${LIB}:O:u}) 684.error ${.CURDIR}: Missing or incorrect _DP_${LIB} entry in ${_this:T}. Should match LIBADD for ${LIB} ('${LIBADD}' vs '${_DP_${LIB}}') 685.endif 686# Note that OBJTOP is not yet defined here but for the purpose of the check 687# it is fine as it resolves to the SRC directory. 688.if !defined(LIB${LIB:tu}DIR) || !exists(${SRCTOP}/${LIB${LIB:tu}DIR:S,^${OBJTOP}/,,}) 689.error ${.CURDIR}: Missing or incorrect value for LIB${LIB:tu}DIR in ${_this:T}: ${LIB${LIB:tu}DIR:S,^${OBJTOP}/,,} 690.endif 691.if ${_INTERNALLIBS:M${LIB}} != "" && !defined(LIB${LIB:tu}) 692.error ${.CURDIR}: Missing value for LIB${LIB:tu} in ${_this:T}. Likely should be: LIB${LIB:tu}?= $${LIB${LIB:tu}DIR}/lib${LIB}.a 693.endif 694.endif 695 696.endif # !target(__<src.libnames.mk>__) 697