Name

confLIBSEARCH

Synopsis

The Build script automatically searches for critical (to sendmail) libraries and, if it finds any, automatically enables specific compile-time options. The list of libraries searched is in the internal confLIBSEARCH macro, which defaults to the following list:

db bind resolv 44bsd

The logic is: if a libdb.a or a libdb.so library is found in any of the directories listed with the confLIBSEARCHPATH macro (confLIBSEARCHPATH), -DNEWDB is automatically[20] defined for confENVDEF (confENVDEF and conf_prog_ENVDEF).

Then the library that is found first (libbind.a, libbind.so, libresolv.a, or libresolv.so) is added to the list of libraries in the confLIBS macro (confLIBS and conf_prog_LIBS). If lib44bsd is found, and if libresolv was the first found, 44bsd is also added to the confLIBS macro.

In the rare instance that this automatic search misconfigures for your site or particular build, you can carefully[21] redefine confLIBSEARCH. For example, suppose db has been installed at your site, but it is broken and you don’t have the time to fix it. You might do this:

dnl ********** Note, removed db until we fix it, bob **********
define(`confLIBSEARCH', `bind resolv 44bsd')

Note that you must use the dnl (delete to newline) directive to form a comment in m4(1).

[20] This is why defining -DNEWDB with confENVDEF sometimes causes two -DNEWDBs to appear when compiling.

[21] Look in devtools/README and in devtools/M4/header.m4 to see how it has been predefined, before redefining ...

Get Sendmail, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.