Changeset 85e9644 for configure


Ignore:
Timestamp:
2006-06-07T13:36:19Z (19 years ago)
Author:
Wilmer van der Gaast <wilmer@…>
Branches:
master
Children:
c121f89
Parents:
a312b6b (diff), 0025b51 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merging Jelmer's storage tree (with LDAP support).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • configure

    ra312b6b r85e9644  
    3131
    3232events=glib
     33ldap=auto
    3334ssl=auto
    3435
     
    6667
    6768--ipv6=0/1      IPv6 socket support                     $ipv6
     69
     70--ldap=0/1/auto LDAP support                            $ldap
    6871
    6972--events=...    Event handler (glib, libevent)          $events
     
    146149
    147150if [ -n "$CC" ]; then
    148         echo "CC=$CC" >> Makefile.settings;
     151        CC=$CC
    149152elif type gcc > /dev/null 2> /dev/null; then
    150         echo "CC=gcc" >> Makefile.settings;
     153        CC=gcc
    151154elif type cc > /dev/null 2> /dev/null; then
    152         echo "CC=cc" >> Makefile.settings;
     155        CC=cc
    153156else
    154157        echo 'Cannot find a C compiler, aborting.'
    155158        exit 1;
    156159fi
     160
     161echo "CC=$CC" >> Makefile.settings;
    157162
    158163if [ -n "$LD" ]; then
     
    230235                ret=0;
    231236        fi;
     237}
     238
     239detect_ldap()
     240{
     241        TMPFILE=`mktemp`
     242        if $CC -o $TMPFILE -shared -lldap 2>/dev/null >/dev/null; then
     243                cat<<EOF>>Makefile.settings
     244EFLAGS+=-lldap
     245CFLAGS+=
     246EOF
     247                ldap=1
     248                rm -f $TMPFILE
     249                ret=1
     250        else
     251                ldap=0
     252                ret=0
     253        fi
    232254}
    233255
     
    292314fi
    293315
     316if [ "$ldap" = "auto" ]; then
     317        detect_ldap
     318fi
     319
     320if [ "$ldap" = 0 ]; then
     321        echo "LDAP_OBJ=\# no ldap" >> Makefile.settings
     322        echo "#undef WITH_LDAP" >> config.h
     323elif [ "$ldap" = 1 ]; then
     324        echo "#define WITH_LDAP 1" >> config.h
     325        echo "LDAP_OBJ=storage_ldap.o" >> Makefile.settings
     326fi
     327
    294328if [ "$strip" = 0 ]; then
    295329        echo "STRIP=\# skip strip" >> Makefile.settings;
     
    444478        echo '  Building without IM-protocol support. We wish you a lot of fun...';
    445479fi
     480
     481if [ "$ldap" = "0" ]; then
     482        echo "  LDAP storage backend disabled."
     483else
     484        echo "  LDAP storage backend enabled."
     485fi
Note: See TracChangeset for help on using the changeset viewer.