Re: config.test fragments

From: Robert Collins <robertc@dont-contact.us>
Date: Tue, 25 Apr 2006 09:10:04 +1000

On Mon, 2006-04-24 at 21:46 +0200, Guido Serassio wrote:
> Hi Duane,
>
> At 21.37 24/04/2006, Duane Wessels wrote:
>
> >>>seems to me that if we exported all the autoconf values during a
> >>>config.test run, they would be more portable: see for instance Guido's
> >>>recent commit to probe /usr/local as well: unless CPPFLAGS are set
> >>>correctly that test won't help (because while its on the system, its not
> >>>available).
> >>
> >>Yes, correct.
> >>On the machine where I have identified the problem, CPPFLAGS is set
> >>correctly, but on other systems this could not be true.
> >
> >I guess this is why ./configure now fails for me:
> >
> > Basic auth helpers built: LDAP MSNT NCSA PAM SASL YP
> > getpwnam multi-domain-NTLM
> > NTLM auth helpers built: SMB fakeauth no_check
> > Digest auth helpers built: ldap password
> > External acl helpers built: ip_user ldap_group session unix_group
> > checking sasl/sasl.h usability... no
> > checking sasl/sasl.h presence... no
> > checking for sasl/sasl.h... no
> > checking sasl.h usability... no
> > checking sasl.h presence... no
> > checking for sasl.h... no
> > ERROR: Neither SASL nor SASL2 found
>
> Sure.
> Probably on your machine sasl.h is placed in /usr/local/include
>
> You can temporary fix the problem adding
> CPPFLAGS="-I/usr/local/include" before the configure command.
>
> We must change things in config.test files.

I don't think headers for optional components should ever cause a
configure failure *unless* a user has explicitly requested that that
component be enabled.

whats happened here is:
if test "$BASIC_AUTH_HELPERS" = "all" ; then
        BASIC_AUTH_HELPERS=""
        for dir in $srcdir/helpers/basic_auth/*; do
            helper="`basename $dir`"
            if test -f $dir/config.test && sh $dir/config.test "$@";
then
                BASIC_AUTH_HELPERS="$BASIC_AUTH_HELPERS $helper"
            fi
        done
fi
-- this block has found sasl as an enabled helper

if test -n "$BASIC_AUTH_HELPERS"; then
    for helper in $BASIC_AUTH_HELPERS; do
        if test -d $srcdir/helpers/basic_auth/$helper; then
            case $helper in
            SASL)
                    require_sasl=yes

-- and this has made it required.
                    ;;
            esac
        else
            echo "ERROR: Basic auth helper $helper does not exists"
            exit 1
        fi
    done
    echo "Basic auth helpers built: $BASIC_AUTH_HELPERS"
fi

So, I think we need to distinguish between 'user said
--basic-auth-helper=sasl' and 'user said --basic-auth-helper=all and
sasl was detected'.

That should fix configure for duane.

Rob

-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.

Received on Mon Apr 24 2006 - 17:10:32 MDT

This archive was generated by hypermail pre-2.1.9 : Mon May 01 2006 - 12:00:03 MDT