[Nut-upsdev] patch for m4/nut_check_libwrap.m4

Tim Rice tim at multitalents.net
Tue Dec 15 18:32:09 UTC 2009


On Tue, 15 Dec 2009, Arjen de Korte wrote:

[snip]
> We have to rely in autoconf finding the proper includes and libraries here.
> What probably needs to be done is reordering some checks we do here and/or
> change from
> 
>    AC_CHECK_LIB(wrap, request_init, [], nut_have_libwrap=no)
> 
> to the preferred way (with possibly some additional search libraries)
> 
>    AC_SEARCH_LIBS(request_init, wrap, [], nut_have_libwrap=no)
> 
> We should really try to avoid using AC_TRY_LINK.

AC_CHECK_LIB or AC_SEARCH_LIBS will fail if libwrap is built as
a shared lib with errors like
.....
Undefined                       first referenced
 symbol                             in file
deny_severity                       /usr/sfw/lib/libwrap.so
allow_severity                      /usr/sfw/lib/libwrap.so
ld: fatal: Symbol referencing errors. No output written to conftest
.....
Using AC_TRY_LINK resolves this.

-- 
Tim Rice				Multitalents	(707) 887-1469
tim at multitalents.net





More information about the Nut-upsdev mailing list