Tomasz Kojm wrote:
On Mon, 27 Sep 2004 17:14:56 +0200
"Tom G. Christensen" <[EMAIL PROTECTED]> wrote:


Hi,

The --disable-dns configure code seems to have an unfortunate
sideeffect in that using --enable-dns will turn off the checking for
dn_expand in -lresolv (and cause the build to crash since -lresolv is
needed later on).


How can I reproduce this error?

When I ran configure with --enable-dns it skipped the test for dn_expand in -lresolv and FRESHCLAM_LIBS ended up not containing -lresolv which made the build stop with unresolved symbols.

Like this:
# ./configure --disable-clamav --without-libcurl
...
checking for bzlib.h... yes
checking for __dn_expand in -lresolv... yes
checking resolv.h usability... yes
checking resolv.h presence... yes
checking for resolv.h... yes
checking whether setpgrp takes no argument... yes
...

The check for dn_expand is performed and it correctly determines that -lresolv is necessary. Build completes succesfully.

Now look at this:
# ./configure --disable-clamav --without-libcurl --enable-dns
...
checking for bzlib.h... yes
checking whether setpgrp takes no argument... yes
...

Oops! The check for dn_expand in -lresolv was *skipped*

You fixed the problem with the build crashing by removing the general test for resolv.h so that HAVE_RESOLV_H would not be defined when the dn_expand test is skipped.
All that's now left is the confusion of --enable-dns *disabling* an option.


The problem is that --disable-dns and --enable-dns is treated the same way when $enableval is not used. It just picks the default for the option which is want_dns=no and thus the test is skipped.

Testsystem is still RHEL 2.1

-tgc
_______________________________________________
http://lists.clamav.net/cgi-bin/mailman/listinfo/clamav-devel

Reply via email to