mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
some changes to make the library working with gcc 3.0 (mostly namespace
stuff). See also ITS#1322
This commit is contained in:
parent
a1ecd9b697
commit
c0dbaa736d
64 changed files with 445 additions and 267 deletions
|
|
@ -80,9 +80,9 @@ ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
|||
mkinstalldirs = $(SHELL) $(top_srcdir)/mkinstalldirs
|
||||
CONFIG_HEADER = ./src/config.h
|
||||
CONFIG_CLEAN_FILES =
|
||||
DIST_COMMON = README AUTHORS INSTALL Makefile.am Makefile.in TODO \
|
||||
aclocal.m4 config.guess config.sub configure configure.in install-sh \
|
||||
ltconfig ltmain.sh missing mkinstalldirs
|
||||
DIST_COMMON = README AUTHORS Makefile.am Makefile.in TODO aclocal.m4 \
|
||||
config.guess config.sub configure configure.in install-sh ltconfig \
|
||||
ltmain.sh missing mkinstalldirs
|
||||
|
||||
|
||||
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
|
||||
|
|
@ -241,7 +241,7 @@ distdir: $(DISTFILES)
|
|||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
if test -d $$d/$$file; then \
|
||||
cp -pr $$/$$file $(distdir)/$$file; \
|
||||
cp -pr $$d/$$file $(distdir)/$$file; \
|
||||
else \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|
|
|
|||
306
contrib/ldapc++/configure
vendored
306
contrib/ldapc++/configure
vendored
|
|
@ -507,6 +507,13 @@ for ac_site_file in $CONFIG_SITE; do
|
|||
fi
|
||||
done
|
||||
|
||||
if test -r "$cache_file"; then
|
||||
echo "loading cache $cache_file"
|
||||
. $cache_file
|
||||
else
|
||||
echo "creating cache $cache_file"
|
||||
> $cache_file
|
||||
fi
|
||||
|
||||
ac_ext=c
|
||||
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
|
||||
|
|
@ -561,7 +568,7 @@ ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
|
|||
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
|
||||
# ./install, which can be erroneously created by make from ./install.sh.
|
||||
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
|
||||
echo "configure:565: checking for a BSD compatible install" >&5
|
||||
echo "configure:572: checking for a BSD compatible install" >&5
|
||||
if test -z "$INSTALL"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -614,7 +621,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
|
|||
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
|
||||
|
||||
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
|
||||
echo "configure:618: checking whether build environment is sane" >&5
|
||||
echo "configure:625: checking whether build environment is sane" >&5
|
||||
# Just in case
|
||||
sleep 1
|
||||
echo timestamp > conftestfile
|
||||
|
|
@ -671,7 +678,7 @@ test "$program_suffix" != NONE &&
|
|||
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
|
||||
|
||||
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
|
||||
echo "configure:675: checking whether ${MAKE-make} sets \${MAKE}" >&5
|
||||
echo "configure:682: checking whether ${MAKE-make} sets \${MAKE}" >&5
|
||||
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -717,7 +724,7 @@ EOF
|
|||
|
||||
missing_dir=`cd $ac_aux_dir && pwd`
|
||||
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
|
||||
echo "configure:721: checking for working aclocal" >&5
|
||||
echo "configure:728: checking for working aclocal" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
|
|
@ -730,7 +737,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
|
||||
echo "configure:734: checking for working autoconf" >&5
|
||||
echo "configure:741: checking for working autoconf" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
|
|
@ -743,7 +750,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for working automake""... $ac_c" 1>&6
|
||||
echo "configure:747: checking for working automake" >&5
|
||||
echo "configure:754: checking for working automake" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
|
|
@ -756,7 +763,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
|
||||
echo "configure:760: checking for working autoheader" >&5
|
||||
echo "configure:767: checking for working autoheader" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
|
|
@ -769,7 +776,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
|
||||
echo "configure:773: checking for working makeinfo" >&5
|
||||
echo "configure:780: checking for working makeinfo" >&5
|
||||
# Run test in a subshell; some versions of sh will print an error if
|
||||
# an executable is not found, even if stderr is redirected.
|
||||
# Redirect stdin to placate older versions of autoconf. Sigh.
|
||||
|
|
@ -799,7 +806,7 @@ fi
|
|||
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
|
||||
# ./install, which can be erroneously created by make from ./install.sh.
|
||||
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
|
||||
echo "configure:803: checking for a BSD compatible install" >&5
|
||||
echo "configure:810: checking for a BSD compatible install" >&5
|
||||
if test -z "$INSTALL"; then
|
||||
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -856,7 +863,7 @@ do
|
|||
# Extract the first word of "$ac_prog", so it can be a program name with args.
|
||||
set dummy $ac_prog; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:860: checking for $ac_word" >&5
|
||||
echo "configure:867: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CXX'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -888,7 +895,7 @@ test -n "$CXX" || CXX="gcc"
|
|||
|
||||
|
||||
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works""... $ac_c" 1>&6
|
||||
echo "configure:892: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
|
||||
echo "configure:899: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) works" >&5
|
||||
|
||||
ac_ext=C
|
||||
# CXXFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
|
||||
|
|
@ -899,12 +906,12 @@ cross_compiling=$ac_cv_prog_cxx_cross
|
|||
|
||||
cat > conftest.$ac_ext << EOF
|
||||
|
||||
#line 903 "configure"
|
||||
#line 910 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
int main(){return(0);}
|
||||
EOF
|
||||
if { (eval echo configure:908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
ac_cv_prog_cxx_works=yes
|
||||
# If we can't run a trivial program, we are probably using a cross compiler.
|
||||
if (./conftest; exit) 2>/dev/null; then
|
||||
|
|
@ -930,12 +937,12 @@ if test $ac_cv_prog_cxx_works = no; then
|
|||
{ echo "configure: error: installation or configuration problem: C++ compiler cannot create executables." 1>&2; exit 1; }
|
||||
fi
|
||||
echo $ac_n "checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
|
||||
echo "configure:934: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
|
||||
echo "configure:941: checking whether the C++ compiler ($CXX $CXXFLAGS $LDFLAGS) is a cross-compiler" >&5
|
||||
echo "$ac_t""$ac_cv_prog_cxx_cross" 1>&6
|
||||
cross_compiling=$ac_cv_prog_cxx_cross
|
||||
|
||||
echo $ac_n "checking whether we are using GNU C++""... $ac_c" 1>&6
|
||||
echo "configure:939: checking whether we are using GNU C++" >&5
|
||||
echo "configure:946: checking whether we are using GNU C++" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_gxx'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -944,7 +951,7 @@ else
|
|||
yes;
|
||||
#endif
|
||||
EOF
|
||||
if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
|
||||
if { ac_try='${CXX-g++} -E conftest.C'; { (eval echo configure:955: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
|
||||
ac_cv_prog_gxx=yes
|
||||
else
|
||||
ac_cv_prog_gxx=no
|
||||
|
|
@ -963,7 +970,7 @@ ac_test_CXXFLAGS="${CXXFLAGS+set}"
|
|||
ac_save_CXXFLAGS="$CXXFLAGS"
|
||||
CXXFLAGS=
|
||||
echo $ac_n "checking whether ${CXX-g++} accepts -g""... $ac_c" 1>&6
|
||||
echo "configure:967: checking whether ${CXX-g++} accepts -g" >&5
|
||||
echo "configure:974: checking whether ${CXX-g++} accepts -g" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_cxx_g'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -994,36 +1001,6 @@ else
|
|||
fi
|
||||
fi
|
||||
|
||||
# Extract the first word of "ranlib", so it can be a program name with args.
|
||||
set dummy ranlib; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1001: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
if test -n "$RANLIB"; then
|
||||
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
|
||||
else
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
||||
ac_dummy="$PATH"
|
||||
for ac_dir in $ac_dummy; do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -f $ac_dir/$ac_word; then
|
||||
ac_cv_prog_RANLIB="ranlib"
|
||||
break
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
|
||||
fi
|
||||
fi
|
||||
RANLIB="$ac_cv_prog_RANLIB"
|
||||
if test -n "$RANLIB"; then
|
||||
echo "$ac_t""$RANLIB" 1>&6
|
||||
else
|
||||
echo "$ac_t""no" 1>&6
|
||||
fi
|
||||
|
||||
# Check whether --enable-shared or --disable-shared was given.
|
||||
if test "${enable_shared+set}" = set; then
|
||||
enableval="$enable_shared"
|
||||
|
|
@ -1100,7 +1077,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
|
|||
fi
|
||||
|
||||
echo $ac_n "checking host system type""... $ac_c" 1>&6
|
||||
echo "configure:1104: checking host system type" >&5
|
||||
echo "configure:1081: checking host system type" >&5
|
||||
|
||||
host_alias=$host
|
||||
case "$host_alias" in
|
||||
|
|
@ -1121,7 +1098,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
|
|||
echo "$ac_t""$host" 1>&6
|
||||
|
||||
echo $ac_n "checking build system type""... $ac_c" 1>&6
|
||||
echo "configure:1125: checking build system type" >&5
|
||||
echo "configure:1102: checking build system type" >&5
|
||||
|
||||
build_alias=$build
|
||||
case "$build_alias" in
|
||||
|
|
@ -1138,10 +1115,40 @@ build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
|
|||
build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
|
||||
echo "$ac_t""$build" 1>&6
|
||||
|
||||
# Extract the first word of "ranlib", so it can be a program name with args.
|
||||
set dummy ranlib; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1122: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
if test -n "$RANLIB"; then
|
||||
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
|
||||
else
|
||||
IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
|
||||
ac_dummy="$PATH"
|
||||
for ac_dir in $ac_dummy; do
|
||||
test -z "$ac_dir" && ac_dir=.
|
||||
if test -f $ac_dir/$ac_word; then
|
||||
ac_cv_prog_RANLIB="ranlib"
|
||||
break
|
||||
fi
|
||||
done
|
||||
IFS="$ac_save_ifs"
|
||||
test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
|
||||
fi
|
||||
fi
|
||||
RANLIB="$ac_cv_prog_RANLIB"
|
||||
if test -n "$RANLIB"; then
|
||||
echo "$ac_t""$RANLIB" 1>&6
|
||||
else
|
||||
echo "$ac_t""no" 1>&6
|
||||
fi
|
||||
|
||||
# Extract the first word of "gcc", so it can be a program name with args.
|
||||
set dummy gcc; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1145: checking for $ac_word" >&5
|
||||
echo "configure:1152: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1171,7 +1178,7 @@ if test -z "$CC"; then
|
|||
# Extract the first word of "cc", so it can be a program name with args.
|
||||
set dummy cc; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1175: checking for $ac_word" >&5
|
||||
echo "configure:1182: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1222,7 +1229,7 @@ fi
|
|||
# Extract the first word of "cl", so it can be a program name with args.
|
||||
set dummy cl; ac_word=$2
|
||||
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
|
||||
echo "configure:1226: checking for $ac_word" >&5
|
||||
echo "configure:1233: checking for $ac_word" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1254,7 +1261,7 @@ fi
|
|||
fi
|
||||
|
||||
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
|
||||
echo "configure:1258: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
|
||||
echo "configure:1265: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
|
||||
|
||||
ac_ext=c
|
||||
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
|
||||
|
|
@ -1265,12 +1272,12 @@ cross_compiling=$ac_cv_prog_cc_cross
|
|||
|
||||
cat > conftest.$ac_ext << EOF
|
||||
|
||||
#line 1269 "configure"
|
||||
#line 1276 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
main(){return(0);}
|
||||
EOF
|
||||
if { (eval echo configure:1274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
ac_cv_prog_cc_works=yes
|
||||
# If we can't run a trivial program, we are probably using a cross compiler.
|
||||
if (./conftest; exit) 2>/dev/null; then
|
||||
|
|
@ -1296,12 +1303,12 @@ if test $ac_cv_prog_cc_works = no; then
|
|||
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
|
||||
fi
|
||||
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
|
||||
echo "configure:1300: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
|
||||
echo "configure:1307: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
|
||||
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
|
||||
cross_compiling=$ac_cv_prog_cc_cross
|
||||
|
||||
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
|
||||
echo "configure:1305: checking whether we are using GNU C" >&5
|
||||
echo "configure:1312: checking whether we are using GNU C" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1310,7 +1317,7 @@ else
|
|||
yes;
|
||||
#endif
|
||||
EOF
|
||||
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1314: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
|
||||
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1321: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
|
||||
ac_cv_prog_gcc=yes
|
||||
else
|
||||
ac_cv_prog_gcc=no
|
||||
|
|
@ -1329,7 +1336,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
|
|||
ac_save_CFLAGS="$CFLAGS"
|
||||
CFLAGS=
|
||||
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
|
||||
echo "configure:1333: checking whether ${CC-cc} accepts -g" >&5
|
||||
echo "configure:1340: checking whether ${CC-cc} accepts -g" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1372,7 +1379,7 @@ ac_prog=ld
|
|||
if test "$ac_cv_prog_gcc" = yes; then
|
||||
# Check if gcc -print-prog-name=ld gives a path.
|
||||
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
|
||||
echo "configure:1376: checking for ld used by GCC" >&5
|
||||
echo "configure:1383: checking for ld used by GCC" >&5
|
||||
ac_prog=`($CC -print-prog-name=ld) 2>&5`
|
||||
case "$ac_prog" in
|
||||
# Accept absolute paths.
|
||||
|
|
@ -1396,10 +1403,10 @@ echo "configure:1376: checking for ld used by GCC" >&5
|
|||
esac
|
||||
elif test "$with_gnu_ld" = yes; then
|
||||
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
|
||||
echo "configure:1400: checking for GNU ld" >&5
|
||||
echo "configure:1407: checking for GNU ld" >&5
|
||||
else
|
||||
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
|
||||
echo "configure:1403: checking for non-GNU ld" >&5
|
||||
echo "configure:1410: checking for non-GNU ld" >&5
|
||||
fi
|
||||
if eval "test \"`echo '$''{'ac_cv_path_LD'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -1434,7 +1441,7 @@ else
|
|||
fi
|
||||
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
|
||||
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
|
||||
echo "configure:1438: checking if the linker ($LD) is GNU ld" >&5
|
||||
echo "configure:1445: checking if the linker ($LD) is GNU ld" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_gnu_ld'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1450,7 +1457,7 @@ echo "$ac_t""$ac_cv_prog_gnu_ld" 1>&6
|
|||
|
||||
|
||||
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
|
||||
echo "configure:1454: checking for BSD-compatible nm" >&5
|
||||
echo "configure:1461: checking for BSD-compatible nm" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_path_NM'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1486,7 +1493,7 @@ NM="$ac_cv_path_NM"
|
|||
echo "$ac_t""$NM" 1>&6
|
||||
|
||||
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
|
||||
echo "configure:1490: checking whether ln -s works" >&5
|
||||
echo "configure:1497: checking whether ln -s works" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
|
|
@ -1535,8 +1542,8 @@ test x"$silent" = xyes && libtool_flags="$libtool_flags --silent"
|
|||
case "$lt_target" in
|
||||
*-*-irix6*)
|
||||
# Find out which ABI we are using.
|
||||
echo '#line 1539 "configure"' > conftest.$ac_ext
|
||||
if { (eval echo configure:1540: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
echo '#line 1546 "configure"' > conftest.$ac_ext
|
||||
if { (eval echo configure:1547: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
case "`/usr/bin/file conftest.o`" in
|
||||
*32-bit*)
|
||||
LD="${LD-ld} -32"
|
||||
|
|
@ -1557,19 +1564,19 @@ case "$lt_target" in
|
|||
SAVE_CFLAGS="$CFLAGS"
|
||||
CFLAGS="$CFLAGS -belf"
|
||||
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
|
||||
echo "configure:1561: checking whether the C compiler needs -belf" >&5
|
||||
echo "configure:1568: checking whether the C compiler needs -belf" >&5
|
||||
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1566 "configure"
|
||||
#line 1573 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
int main() {
|
||||
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
lt_cv_cc_needs_belf=yes
|
||||
else
|
||||
|
|
@ -1593,6 +1600,52 @@ esac
|
|||
|
||||
|
||||
# Save cache, so that ltconfig can load it
|
||||
cat > confcache <<\EOF
|
||||
# This file is a shell script that caches the results of configure
|
||||
# tests run on this system so they can be shared between configure
|
||||
# scripts and configure runs. It is not useful on other systems.
|
||||
# If it contains results you don't want to keep, you may remove or edit it.
|
||||
#
|
||||
# By default, configure uses ./config.cache as the cache file,
|
||||
# creating it if it does not exist already. You can give configure
|
||||
# the --cache-file=FILE option to use a different cache file; that is
|
||||
# what configure does when it calls configure scripts in
|
||||
# subdirectories, so they share the cache.
|
||||
# Giving --cache-file=/dev/null disables caching, for debugging configure.
|
||||
# config.status only pays attention to the cache file if you give it the
|
||||
# --recheck option to rerun configure.
|
||||
#
|
||||
EOF
|
||||
# The following way of writing the cache mishandles newlines in values,
|
||||
# but we know of no workaround that is simple, portable, and efficient.
|
||||
# So, don't put newlines in cache variables' values.
|
||||
# Ultrix sh set writes to stderr and can't be redirected directly,
|
||||
# and sets the high bit in the cache file unless we assign to the vars.
|
||||
(set) 2>&1 |
|
||||
case `(ac_space=' '; set | grep ac_space) 2>&1` in
|
||||
*ac_space=\ *)
|
||||
# `set' does not quote correctly, so add quotes (double-quote substitution
|
||||
# turns \\\\ into \\, and sed turns \\ into \).
|
||||
sed -n \
|
||||
-e "s/'/'\\\\''/g" \
|
||||
-e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
|
||||
;;
|
||||
*)
|
||||
# `set' quotes correctly as required by POSIX, so do not add quotes.
|
||||
sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
|
||||
;;
|
||||
esac >> confcache
|
||||
if cmp -s $cache_file confcache; then
|
||||
:
|
||||
else
|
||||
if test -w $cache_file; then
|
||||
echo "updating cache $cache_file"
|
||||
cat confcache > $cache_file
|
||||
else
|
||||
echo "not updating unwritable cache $cache_file"
|
||||
fi
|
||||
fi
|
||||
rm -f confcache
|
||||
|
||||
|
||||
# Actually configure libtool. ac_aux_dir is where install-sh is found.
|
||||
|
|
@ -1605,6 +1658,13 @@ $libtool_flags --no-verify $ac_aux_dir/ltmain.sh $lt_target \
|
|||
|| { echo "configure: error: libtool configure failed" 1>&2; exit 1; }
|
||||
|
||||
# Reload cache, that may have been modified by ltconfig
|
||||
if test -r "$cache_file"; then
|
||||
echo "loading cache $cache_file"
|
||||
. $cache_file
|
||||
else
|
||||
echo "creating cache $cache_file"
|
||||
> $cache_file
|
||||
fi
|
||||
|
||||
|
||||
# This can be used to rebuild libtool when needed
|
||||
|
|
@ -1663,7 +1723,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for main in -lresolv""... $ac_c" 1>&6
|
||||
echo "configure:1667: checking for main in -lresolv" >&5
|
||||
echo "configure:1727: checking for main in -lresolv" >&5
|
||||
ac_lib_var=`echo resolv'_'main | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -1671,14 +1731,14 @@ else
|
|||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-lresolv $LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1675 "configure"
|
||||
#line 1735 "configure"
|
||||
#include "confdefs.h"
|
||||
|
||||
int main() {
|
||||
main()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||
else
|
||||
|
|
@ -1706,7 +1766,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for ber_strdup in -llber""... $ac_c" 1>&6
|
||||
echo "configure:1710: checking for ber_strdup in -llber" >&5
|
||||
echo "configure:1770: checking for ber_strdup in -llber" >&5
|
||||
ac_lib_var=`echo lber'_'ber_strdup | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -1714,7 +1774,7 @@ else
|
|||
ac_save_LIBS="$LIBS"
|
||||
LIBS="-llber $LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1718 "configure"
|
||||
#line 1778 "configure"
|
||||
#include "confdefs.h"
|
||||
/* Override any gcc2 internal prototype to avoid an error. */
|
||||
/* We use char because int might match the return type of a gcc2
|
||||
|
|
@ -1725,7 +1785,7 @@ int main() {
|
|||
ber_strdup()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||
else
|
||||
|
|
@ -1741,6 +1801,7 @@ fi
|
|||
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
|
||||
echo "$ac_t""yes" 1>&6
|
||||
|
||||
:
|
||||
|
||||
else
|
||||
echo "$ac_t""no" 1>&6
|
||||
|
|
@ -1753,7 +1814,7 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking for ldap_add_ext in -lldap""... $ac_c" 1>&6
|
||||
echo "configure:1757: checking for ldap_add_ext in -lldap" >&5
|
||||
echo "configure:1818: checking for ldap_add_ext in -lldap" >&5
|
||||
ac_lib_var=`echo ldap'_'ldap_add_ext | sed 'y%./+-%__p_%'`
|
||||
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
|
|
@ -1763,7 +1824,7 @@ LIBS="-lldap
|
|||
-llber
|
||||
$LIBS"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1767 "configure"
|
||||
#line 1828 "configure"
|
||||
#include "confdefs.h"
|
||||
/* Override any gcc2 internal prototype to avoid an error. */
|
||||
/* We use char because int might match the return type of a gcc2
|
||||
|
|
@ -1774,7 +1835,7 @@ int main() {
|
|||
ldap_add_ext()
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1778: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
if { (eval echo configure:1839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
|
||||
rm -rf conftest*
|
||||
eval "ac_cv_lib_$ac_lib_var=yes"
|
||||
else
|
||||
|
|
@ -1790,6 +1851,7 @@ fi
|
|||
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
|
||||
echo "$ac_t""yes" 1>&6
|
||||
|
||||
:
|
||||
|
||||
else
|
||||
echo "$ac_t""no" 1>&6
|
||||
|
|
@ -1802,12 +1864,12 @@ else
|
|||
fi
|
||||
|
||||
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
|
||||
echo "configure:1806: checking whether time.h and sys/time.h may both be included" >&5
|
||||
echo "configure:1868: checking whether time.h and sys/time.h may both be included" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1811 "configure"
|
||||
#line 1873 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
|
|
@ -1816,7 +1878,7 @@ int main() {
|
|||
struct tm *tp;
|
||||
; return 0; }
|
||||
EOF
|
||||
if { (eval echo configure:1820: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
if { (eval echo configure:1882: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
|
||||
rm -rf conftest*
|
||||
ac_cv_header_time=yes
|
||||
else
|
||||
|
|
@ -1837,7 +1899,7 @@ EOF
|
|||
fi
|
||||
|
||||
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
|
||||
echo "configure:1841: checking how to run the C preprocessor" >&5
|
||||
echo "configure:1903: checking how to run the C preprocessor" >&5
|
||||
# On Suns, sometimes $CPP names a directory.
|
||||
if test -n "$CPP" && test -d "$CPP"; then
|
||||
CPP=
|
||||
|
|
@ -1852,13 +1914,13 @@ else
|
|||
# On the NeXT, cc -E runs the code through the compiler's parser,
|
||||
# not just through cpp.
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1856 "configure"
|
||||
#line 1918 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1924: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
|
|
@ -1869,13 +1931,13 @@ else
|
|||
rm -rf conftest*
|
||||
CPP="${CC-cc} -E -traditional-cpp"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1873 "configure"
|
||||
#line 1935 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1879: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1941: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
|
|
@ -1886,13 +1948,13 @@ else
|
|||
rm -rf conftest*
|
||||
CPP="${CC-cc} -nologo -E"
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1890 "configure"
|
||||
#line 1952 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <assert.h>
|
||||
Syntax Error
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1896: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
:
|
||||
|
|
@ -1918,17 +1980,17 @@ echo "$ac_t""$CPP" 1>&6
|
|||
|
||||
ac_safe=`echo "ldap.h" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for ldap.h""... $ac_c" 1>&6
|
||||
echo "configure:1922: checking for ldap.h" >&5
|
||||
echo "configure:1984: checking for ldap.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1927 "configure"
|
||||
#line 1989 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <ldap.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1932: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:1994: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
|
@ -1950,7 +2012,7 @@ else
|
|||
fi
|
||||
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1954 "configure"
|
||||
#line 2016 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <ldap.h>
|
||||
EOF
|
||||
|
|
@ -1958,6 +2020,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
|||
egrep "ldap_add_ext" >/dev/null 2>&1; then
|
||||
rm -rf conftest*
|
||||
|
||||
:
|
||||
|
||||
else
|
||||
rm -rf conftest*
|
||||
|
|
@ -1972,17 +2035,17 @@ rm -f conftest*
|
|||
|
||||
ac_safe=`echo "lber.h" | sed 'y%./+-%__p_%'`
|
||||
echo $ac_n "checking for lber.h""... $ac_c" 1>&6
|
||||
echo "configure:1976: checking for lber.h" >&5
|
||||
echo "configure:2039: checking for lber.h" >&5
|
||||
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
|
||||
echo $ac_n "(cached) $ac_c" 1>&6
|
||||
else
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 1981 "configure"
|
||||
#line 2044 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <lber.h>
|
||||
EOF
|
||||
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
|
||||
{ (eval echo configure:1986: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
{ (eval echo configure:2049: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
|
||||
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
|
||||
if test -z "$ac_err"; then
|
||||
rm -rf conftest*
|
||||
|
|
@ -2004,7 +2067,7 @@ else
|
|||
fi
|
||||
|
||||
cat > conftest.$ac_ext <<EOF
|
||||
#line 2008 "configure"
|
||||
#line 2071 "configure"
|
||||
#include "confdefs.h"
|
||||
#include <lber.h>
|
||||
EOF
|
||||
|
|
@ -2012,6 +2075,7 @@ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
|
|||
egrep "ber_strdup" >/dev/null 2>&1; then
|
||||
rm -rf conftest*
|
||||
|
||||
:
|
||||
|
||||
else
|
||||
rm -rf conftest*
|
||||
|
|
@ -2028,6 +2092,52 @@ rm -f conftest*
|
|||
|
||||
|
||||
trap '' 1 2 15
|
||||
cat > confcache <<\EOF
|
||||
# This file is a shell script that caches the results of configure
|
||||
# tests run on this system so they can be shared between configure
|
||||
# scripts and configure runs. It is not useful on other systems.
|
||||
# If it contains results you don't want to keep, you may remove or edit it.
|
||||
#
|
||||
# By default, configure uses ./config.cache as the cache file,
|
||||
# creating it if it does not exist already. You can give configure
|
||||
# the --cache-file=FILE option to use a different cache file; that is
|
||||
# what configure does when it calls configure scripts in
|
||||
# subdirectories, so they share the cache.
|
||||
# Giving --cache-file=/dev/null disables caching, for debugging configure.
|
||||
# config.status only pays attention to the cache file if you give it the
|
||||
# --recheck option to rerun configure.
|
||||
#
|
||||
EOF
|
||||
# The following way of writing the cache mishandles newlines in values,
|
||||
# but we know of no workaround that is simple, portable, and efficient.
|
||||
# So, don't put newlines in cache variables' values.
|
||||
# Ultrix sh set writes to stderr and can't be redirected directly,
|
||||
# and sets the high bit in the cache file unless we assign to the vars.
|
||||
(set) 2>&1 |
|
||||
case `(ac_space=' '; set | grep ac_space) 2>&1` in
|
||||
*ac_space=\ *)
|
||||
# `set' does not quote correctly, so add quotes (double-quote substitution
|
||||
# turns \\\\ into \\, and sed turns \\ into \).
|
||||
sed -n \
|
||||
-e "s/'/'\\\\''/g" \
|
||||
-e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
|
||||
;;
|
||||
*)
|
||||
# `set' quotes correctly as required by POSIX, so do not add quotes.
|
||||
sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
|
||||
;;
|
||||
esac >> confcache
|
||||
if cmp -s $cache_file confcache; then
|
||||
:
|
||||
else
|
||||
if test -w $cache_file; then
|
||||
echo "updating cache $cache_file"
|
||||
cat confcache > $cache_file
|
||||
else
|
||||
echo "not updating unwritable cache $cache_file"
|
||||
fi
|
||||
fi
|
||||
rm -f confcache
|
||||
|
||||
trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
|
||||
|
||||
|
|
@ -2126,7 +2236,6 @@ s%@AUTOHEADER@%$AUTOHEADER%g
|
|||
s%@MAKEINFO@%$MAKEINFO%g
|
||||
s%@SET_MAKE@%$SET_MAKE%g
|
||||
s%@CXX@%$CXX%g
|
||||
s%@RANLIB@%$RANLIB%g
|
||||
s%@host@%$host%g
|
||||
s%@host_alias@%$host_alias%g
|
||||
s%@host_cpu@%$host_cpu%g
|
||||
|
|
@ -2137,6 +2246,7 @@ s%@build_alias@%$build_alias%g
|
|||
s%@build_cpu@%$build_cpu%g
|
||||
s%@build_vendor@%$build_vendor%g
|
||||
s%@build_os@%$build_os%g
|
||||
s%@RANLIB@%$RANLIB%g
|
||||
s%@CC@%$CC%g
|
||||
s%@LN_S@%$LN_S%g
|
||||
s%@LIBTOOL@%$LIBTOOL%g
|
||||
|
|
|
|||
|
|
@ -5,8 +5,8 @@ dnl COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
|||
dnl Process this file with autoconf to produce a configure script.
|
||||
|
||||
dnl disable config.cache
|
||||
define([AC_CACHE_LOAD], )
|
||||
define([AC_CACHE_SAVE], )
|
||||
dnl define([AC_CACHE_LOAD], )
|
||||
dnl define([AC_CACHE_SAVE], )
|
||||
|
||||
AC_INIT(src/main.cpp)
|
||||
AM_INIT_AUTOMAKE(main, 0.0.1)
|
||||
|
|
@ -17,7 +17,7 @@ dnl Checks for programs.
|
|||
AC_PROG_INSTALL
|
||||
dnl AC_PROG_CC
|
||||
AC_PROG_CXX
|
||||
AC_PROG_RANLIB
|
||||
dnl AC_PROG_RANLIB
|
||||
dnl AM_DISABLE_SHARED
|
||||
AM_PROG_LIBTOOL
|
||||
dnl AC_PROG_MAKE_SET
|
||||
|
|
@ -45,6 +45,8 @@ AC_ARG_WITH(ldap-includes,[ --with-ldap-includes=DIR Path to the libldap inc
|
|||
dnl Checks for libraries.
|
||||
AC_CHECK_LIB(resolv,main)
|
||||
AC_CHECK_LIB(lber,ber_strdup,[
|
||||
dnl NOOP
|
||||
:
|
||||
],[
|
||||
echo " didn't find ber_strdup in liblber !";
|
||||
echo " Check for the right version (>= 2.0) of the OpenLDAP libraries";
|
||||
|
|
@ -52,6 +54,8 @@ AC_CHECK_LIB(lber,ber_strdup,[
|
|||
exit
|
||||
])
|
||||
AC_CHECK_LIB(ldap,ldap_add_ext,[
|
||||
dnl NOOP
|
||||
:
|
||||
],[
|
||||
echo " didn't find ldap_add_ext in libldap !";
|
||||
echo " Check for the right version (>= 2.0) of the OpenLDAP libraries";
|
||||
|
|
@ -64,6 +68,8 @@ dnl Checks for header files.
|
|||
AC_HEADER_TIME
|
||||
AC_CHECK_HEADER(ldap.h)
|
||||
AC_EGREP_HEADER(ldap_add_ext,ldap.h,[
|
||||
dnl NOOP
|
||||
:
|
||||
],[
|
||||
echo " didn't find ldap_add_ext in ldap.h!";
|
||||
echo " Check for the right version (>= 2.0) of the OpenLDAP includes";
|
||||
|
|
@ -72,6 +78,8 @@ AC_EGREP_HEADER(ldap_add_ext,ldap.h,[
|
|||
])
|
||||
AC_CHECK_HEADER(lber.h)
|
||||
AC_EGREP_HEADER(ber_strdup,lber.h,[
|
||||
dnl NOOP
|
||||
:
|
||||
],[
|
||||
echo " didn't find ber_strdup in lber.h!";
|
||||
echo " Check for the right version (>= 2.0) of the OpenLDAP includes";
|
||||
|
|
|
|||
|
|
@ -14,6 +14,8 @@
|
|||
#include "LDAPMessageQueue.h"
|
||||
#include "LDAPResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPAddRequest::LDAPAddRequest(const LDAPAddRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT, "LDAPAddRequest::LDAPAddRequest(&)" << endl);
|
||||
|
|
|
|||
|
|
@ -22,6 +22,8 @@
|
|||
#include "LDAPRebindAuth.h"
|
||||
#include "LDAPSearchRequest.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPAsynConnection::LDAPAsynConnection(const string& hostname, int port,
|
||||
LDAPConstraints *cons ){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPAsynConnection::LDAPAsynConnection()"
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ class LDAPAsynConnection{
|
|||
* @param cons Default constraints to use with operations over
|
||||
* this connection
|
||||
*/
|
||||
LDAPAsynConnection(const string& hostname=string("localhost"),
|
||||
LDAPAsynConnection(const std::string& hostname=std::string("localhost"),
|
||||
int port=389, LDAPConstraints *cons=new LDAPConstraints() );
|
||||
|
||||
//* Destructor
|
||||
|
|
@ -87,7 +87,7 @@ class LDAPAsynConnection{
|
|||
* LDAP-Server
|
||||
* @param port The Network Port the server is running on
|
||||
*/
|
||||
void init(const string& hostname, int port);
|
||||
void init(const std::string& hostname, int port);
|
||||
|
||||
/**
|
||||
* Start TLS on this connection. This isn't in the constructor,
|
||||
|
|
@ -107,7 +107,7 @@ class LDAPAsynConnection{
|
|||
* @param dn the distiguished name to bind as
|
||||
* @param passwd cleartext password to use
|
||||
*/
|
||||
LDAPMessageQueue* bind(const string& dn="", const string& passwd="",
|
||||
LDAPMessageQueue* bind(const std::string& dn="", const std::string& passwd="",
|
||||
const LDAPConstraints *cons=0);
|
||||
|
||||
/** Performing a search on a directory tree.
|
||||
|
|
@ -122,15 +122,15 @@ class LDAPAsynConnection{
|
|||
* LDAPAsynConnection::SEARCH_BASE, <BR>
|
||||
* LDAPAsynConnection::SEARCH_ONE, <BR>
|
||||
* LDAPAsynConnection::SEARCH_SUB
|
||||
* @param filter The string representation of a search filter to
|
||||
* @param filter The std::string representation of a search filter to
|
||||
* use with this operation
|
||||
* @param attrsOnly true if only the attributes names (no values)
|
||||
* should be returned
|
||||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
LDAPMessageQueue* search(const string& base="", int scope=0,
|
||||
const string& filter="objectClass=*",
|
||||
LDAPMessageQueue* search(const std::string& base="", int scope=0,
|
||||
const std::string& filter="objectClass=*",
|
||||
const StringList& attrs=StringList(),
|
||||
bool attrsOnly=false,
|
||||
const LDAPConstraints *cons=0);
|
||||
|
|
@ -145,7 +145,7 @@ class LDAPAsynConnection{
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
LDAPMessageQueue* del(const string& dn, const LDAPConstraints *cons=0);
|
||||
LDAPMessageQueue* del(const std::string& dn, const LDAPConstraints *cons=0);
|
||||
|
||||
/**
|
||||
* Perform the COMPARE-operation on an attribute
|
||||
|
|
@ -160,7 +160,7 @@ class LDAPAsynConnection{
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
LDAPMessageQueue* compare(const string& dn, const LDAPAttribute& attr,
|
||||
LDAPMessageQueue* compare(const std::string& dn, const LDAPAttribute& attr,
|
||||
const LDAPConstraints *cons=0);
|
||||
|
||||
/** Add an entry to the directory
|
||||
|
|
@ -179,12 +179,12 @@ class LDAPAsynConnection{
|
|||
* destination server, a LDAPException-object contains the
|
||||
* error that occured.
|
||||
* @param dn Distiguished Name of the Entry to modify
|
||||
* @param modlist A set of modification that should be applied
|
||||
* @param modstd::list A set of modification that should be applied
|
||||
* to the Entry
|
||||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
LDAPMessageQueue* modify(const string& dn, const LDAPModList *modlist,
|
||||
LDAPMessageQueue* modify(const std::string& dn, const LDAPModList *modlist,
|
||||
const LDAPConstraints *cons=0);
|
||||
|
||||
/** modify the DN of an entry
|
||||
|
|
@ -201,8 +201,8 @@ class LDAPAsynConnection{
|
|||
* @param newParentDN The DN of the new parent entry of the entry
|
||||
* 0 to keep the old one
|
||||
*/
|
||||
LDAPMessageQueue* rename(const string& dn, const string& newRDN,
|
||||
bool delOldRDN=false, const string& newParentDN="",
|
||||
LDAPMessageQueue* rename(const std::string& dn, const std::string& newRDN,
|
||||
bool delOldRDN=false, const std::string& newParentDN="",
|
||||
const LDAPConstraints* cons=0);
|
||||
|
||||
/** Perform a LDAP extended Operation
|
||||
|
|
@ -216,8 +216,8 @@ class LDAPAsynConnection{
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
LDAPMessageQueue* extOperation(const string& oid,
|
||||
const string& value="", const LDAPConstraints *cons=0);
|
||||
LDAPMessageQueue* extOperation(const std::string& oid,
|
||||
const std::string& value="", const LDAPConstraints *cons=0);
|
||||
|
||||
/** End an outstanding request
|
||||
*
|
||||
|
|
@ -243,7 +243,7 @@ class LDAPAsynConnection{
|
|||
* @returns The Hostname of the destination server of the
|
||||
* connection.
|
||||
*/
|
||||
const string& getHost() const;
|
||||
const std::string& getHost() const;
|
||||
|
||||
/**
|
||||
* @returns The Port to which this connection is connecting to on
|
||||
|
|
@ -270,7 +270,7 @@ class LDAPAsynConnection{
|
|||
* referral.
|
||||
*
|
||||
* @throws LDAPException in any case of an error
|
||||
* @param urls Contains a list of LDAP-Urls that indicate the
|
||||
* @param urls Contains a std::list of LDAP-Urls that indicate the
|
||||
* destinations of a referral
|
||||
* @param usedUrl After this method has successfully bind to one of
|
||||
* the Destination URLs this parameter contains the URLs
|
||||
|
|
@ -293,7 +293,7 @@ class LDAPAsynConnection{
|
|||
/// is cacheEnabled?
|
||||
bool getCacheEnabled() { return m_cacheEnabled;};
|
||||
/// uncache a specific dn. Used internally by methods that write.
|
||||
void uncache_entry(string &dn);
|
||||
void uncache_entry(std::string &dn);
|
||||
/// used to clear the cache. Probably should be used after creating
|
||||
/// an object that a cached search should find.
|
||||
void flush_cache();
|
||||
|
|
@ -321,7 +321,7 @@ class LDAPAsynConnection{
|
|||
/**
|
||||
* The name of the destination host
|
||||
*/
|
||||
string m_host;
|
||||
std::string m_host;
|
||||
|
||||
/**
|
||||
* The port the destination server is running on.
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@
|
|||
|
||||
#include "LDAPAttribute.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPAttribute::LDAPAttribute(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT, "LDAPAttribute::LDAPAttribute( )" << endl);
|
||||
|
|
|
|||
|
|
@ -33,16 +33,16 @@ class LDAPAttribute{
|
|||
LDAPAttribute(const LDAPAttribute& attr);
|
||||
|
||||
/**
|
||||
* Construct an Attribute with a single string value
|
||||
* Construct an Attribute with a single std::string value
|
||||
* @param name The attribute's name (type)
|
||||
* @param value The string value of the attribute, if "" the
|
||||
* @param value The std::string value of the attribute, if "" the
|
||||
* attribute will have no values, for LDAPv3
|
||||
* this values must be UTF-8 encoded
|
||||
*/
|
||||
LDAPAttribute(const string& name, const string& value="");
|
||||
LDAPAttribute(const std::string& name, const std::string& value="");
|
||||
|
||||
/**
|
||||
* Construct an attribute with multiple string values
|
||||
* Construct an attribute with multiple std::string values
|
||||
* @param name The attribute's name (type)
|
||||
* @param values A 0-terminated array of char*. Each char* specifies
|
||||
* one value of the attribute (UTF-8 encoded)
|
||||
|
|
@ -50,13 +50,13 @@ class LDAPAttribute{
|
|||
LDAPAttribute(const char* name, char **values);
|
||||
|
||||
/**
|
||||
* Construct an attribute with multiple string values
|
||||
* Construct an attribute with multiple std::string values
|
||||
* @param name The attribute's name (type)
|
||||
* @param values A list of strings. Each element specifies
|
||||
* @param values A std::list of std::strings. Each element specifies
|
||||
* one value of the attribute (UTF-8 or binary
|
||||
* encoded)
|
||||
*/
|
||||
LDAPAttribute(const string& name, const StringList& values);
|
||||
LDAPAttribute(const std::string& name, const StringList& values);
|
||||
|
||||
/**
|
||||
* Construct an attribute with multiple binary coded values
|
||||
|
|
@ -76,11 +76,11 @@ class LDAPAttribute{
|
|||
~LDAPAttribute();
|
||||
|
||||
/**
|
||||
* Add a single string value(bin/char) to the Attribute
|
||||
* Add a single std::string value(bin/char) to the Attribute
|
||||
* @param value Value that should be added, it is copied inside the
|
||||
* object
|
||||
*/
|
||||
void addValue(const string& value);
|
||||
void addValue(const std::string& value);
|
||||
|
||||
/**
|
||||
* Add a single binary value to the Attribute
|
||||
|
|
@ -95,7 +95,7 @@ class LDAPAttribute{
|
|||
* Set the values of the attribute. If the object contains some values
|
||||
* already, they are deleted
|
||||
* @param values 0-terminated array of char*, each char*
|
||||
* representing a string value to add to the entry
|
||||
* representing a std::string value to add to the entry
|
||||
*
|
||||
* @return 0 no problem <BR>
|
||||
* -1 failure (mem. allocation problem)
|
||||
|
|
@ -116,8 +116,8 @@ class LDAPAttribute{
|
|||
/**
|
||||
* Set the values of the attribute. If the object does already contain
|
||||
* some values, they will be deleted
|
||||
* @param values A list of string-Objects. Each string is
|
||||
* representing a string or binary value to add to
|
||||
* @param values A std::list of std::string-Objects. Each std::string is
|
||||
* representing a std::string or binary value to add to
|
||||
* the entry
|
||||
*/
|
||||
void setValues(const StringList& values);
|
||||
|
|
@ -134,7 +134,7 @@ class LDAPAttribute{
|
|||
BerValue** getBerValues() const;
|
||||
|
||||
/**
|
||||
* @return The values of the array as a list of strings
|
||||
* @return The values of the array as a std::list of std::strings
|
||||
*/
|
||||
const StringList& getValues() const;
|
||||
|
||||
|
|
@ -146,13 +146,13 @@ class LDAPAttribute{
|
|||
/**
|
||||
* @return The name(type) of the attribute
|
||||
*/
|
||||
const string& getName() const ;
|
||||
const std::string& getName() const ;
|
||||
|
||||
/**
|
||||
* Sets the Attribute's name (type)
|
||||
* @param the new name of the object
|
||||
*/
|
||||
void setName(const string& name);
|
||||
void setName(const std::string& name);
|
||||
|
||||
/**
|
||||
* For internal use only.
|
||||
|
|
@ -168,13 +168,13 @@ class LDAPAttribute{
|
|||
bool isNotPrintable() const ;
|
||||
|
||||
private :
|
||||
string m_name;
|
||||
std::string m_name;
|
||||
StringList m_values;
|
||||
|
||||
/**
|
||||
* This method can be used to dump the data of a LDAPResult-Object.
|
||||
* It is only useful for debugging purposes at the moment
|
||||
*/
|
||||
friend ostream& operator << (ostream& s, const LDAPAttribute& attr);
|
||||
friend std::ostream& operator << (std::ostream& s, const LDAPAttribute& attr);
|
||||
};
|
||||
#endif //#ifndef LDAP_ATTRIBUTE_H
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@
|
|||
* COPYING RESTRICTIONS APPLY, see COPYRIGHT file
|
||||
*/
|
||||
|
||||
#include <ldap.h>
|
||||
|
||||
#include "debug.h"
|
||||
|
||||
|
|
@ -14,6 +13,8 @@
|
|||
#include "LDAPAsynConnection.h"
|
||||
#include "LDAPMessage.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPAttributeList::LDAPAttributeList(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
"LDAPAttributeList::LDAPAttributList( )" << endl);
|
||||
|
|
|
|||
|
|
@ -7,12 +7,13 @@
|
|||
#ifndef LDAP_ATTRIBUTE_LIST_H
|
||||
#define LDAP_ATTRIBUTE_LIST_H
|
||||
|
||||
#include <ldap.h>
|
||||
#include <list>
|
||||
class LDAPAttribute;
|
||||
class LDAPAsynConnection;
|
||||
class LDAPMsg;
|
||||
|
||||
typedef list<LDAPAttribute> AttrList;
|
||||
typedef std::list<LDAPAttribute> AttrList;
|
||||
|
||||
/**
|
||||
* This container class is used to store multiple LDAPAttribute-objects.
|
||||
|
|
@ -88,7 +89,8 @@ class LDAPAttributeList{
|
|||
* This method can be used to dump the data of a LDAPResult-Object.
|
||||
* It is only useful for debugging purposes at the moment
|
||||
*/
|
||||
friend ostream& operator << (ostream& s, const LDAPAttributeList& al);
|
||||
friend std::ostream& operator << (std::ostream& s,
|
||||
const LDAPAttributeList& al);
|
||||
};
|
||||
#endif // LDAP_ATTRIBUTE_LIST_H
|
||||
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@
|
|||
#include "LDAPBindRequest.h"
|
||||
#include "LDAPException.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPBindRequest::LDAPBindRequest(const LDAPBindRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT, "LDAPBindRequest::LDAPBindRequest(&)" << endl);
|
||||
|
|
@ -69,7 +71,7 @@ LDAPMessageQueue* LDAPBindRequest::sendRequest(){
|
|||
}
|
||||
}
|
||||
|
||||
LDAPRequest* LDAPBindRequest::followReferral(LDAPMsg* urls){
|
||||
LDAPRequest* LDAPBindRequest::followReferral(LDAPMsg* /*urls*/){
|
||||
DEBUG(LDAP_DEBUG_TRACE,"LDAPBindRequest::followReferral()" << endl);
|
||||
DEBUG(LDAP_DEBUG_TRACE,
|
||||
"ReferralChasing for bind-operation not implemented yet" << endl);
|
||||
|
|
|
|||
|
|
@ -10,14 +10,14 @@
|
|||
|
||||
class LDAPBindRequest : LDAPRequest {
|
||||
private:
|
||||
string m_dn;
|
||||
string m_cred;
|
||||
string m_mech;
|
||||
std::string m_dn;
|
||||
std::string m_cred;
|
||||
std::string m_mech;
|
||||
|
||||
public:
|
||||
LDAPBindRequest(const LDAPBindRequest& req);
|
||||
//just for simple authentication
|
||||
LDAPBindRequest(const string&, const string& passwd,
|
||||
LDAPBindRequest(const std::string&, const std::string& passwd,
|
||||
LDAPAsynConnection *connect, const LDAPConstraints *cons,
|
||||
bool isReferral=false);
|
||||
virtual ~LDAPBindRequest();
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPMessageQueue.h"
|
||||
#include "LDAPResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPCompareRequest::LDAPCompareRequest(const LDAPCompareRequest& req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
"LDAPCompareRequest::LDAPCompareRequest(&)" << endl);
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@ class LDAPMessageQueue;
|
|||
class LDAPCompareRequest : public LDAPRequest {
|
||||
public :
|
||||
LDAPCompareRequest(const LDAPCompareRequest& req);
|
||||
LDAPCompareRequest(const string& dn, const LDAPAttribute& attr,
|
||||
LDAPCompareRequest(const std::string& dn, const LDAPAttribute& attr,
|
||||
LDAPAsynConnection *connect, const LDAPConstraints *cons,
|
||||
bool isReferral=false, const LDAPRequest* parent=0);
|
||||
virtual ~LDAPCompareRequest();
|
||||
|
|
@ -21,7 +21,7 @@ class LDAPCompareRequest : public LDAPRequest {
|
|||
virtual LDAPRequest* followReferral(LDAPMsg* urls);
|
||||
|
||||
private :
|
||||
string m_dn;
|
||||
std::string m_dn;
|
||||
LDAPAttribute m_attr;
|
||||
|
||||
};
|
||||
|
|
|
|||
|
|
@ -15,6 +15,8 @@ const int LDAPConnection::SEARCH_BASE = LDAPAsynConnection::SEARCH_BASE;
|
|||
const int LDAPConnection::SEARCH_ONE = LDAPAsynConnection::SEARCH_ONE;
|
||||
const int LDAPConnection::SEARCH_SUB = LDAPAsynConnection::SEARCH_SUB;
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPConnection::LDAPConnection(const string& hostname, int port,
|
||||
LDAPConstraints* cons) :
|
||||
LDAPAsynConnection(hostname, port, cons){
|
||||
|
|
@ -333,24 +335,20 @@ const LDAPConstraints* LDAPConnection::getConstraints() const{
|
|||
return LDAPAsynConnection::getConstraints();
|
||||
}
|
||||
|
||||
int LDAPConnection::enableCache(long timeout, long maxmem)
|
||||
{
|
||||
int LDAPConnection::enableCache(long timeout, long maxmem) {
|
||||
return LDAPAsynConnection::enableCache(timeout, maxmem);
|
||||
}
|
||||
|
||||
|
||||
void LDAPConnection::disableCache()
|
||||
{
|
||||
void LDAPConnection::disableCache() {
|
||||
LDAPAsynConnection::disableCache();
|
||||
}
|
||||
|
||||
bool LDAPConnection::getCacheEnabled()
|
||||
{
|
||||
bool LDAPConnection::getCacheEnabled() {
|
||||
return LDAPAsynConnection::getCacheEnabled();
|
||||
}
|
||||
|
||||
void LDAPConnection::uncache_entry(string &dn)
|
||||
{
|
||||
void LDAPConnection::uncache_entry(string &dn) {
|
||||
LDAPAsynConnection::uncache_entry(dn);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @param cons Default constraints to use with operations over
|
||||
* this connection
|
||||
*/
|
||||
LDAPConnection(const string& hostname="localhost", int port=389,
|
||||
LDAPConnection(const std::string& hostname="localhost", int port=389,
|
||||
LDAPConstraints* cons=new LDAPConstraints());
|
||||
|
||||
/**
|
||||
|
|
@ -66,7 +66,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* LDAP-Server
|
||||
* @param port The Network Port the server is running on
|
||||
*/
|
||||
void init(const string& hostname, int port);
|
||||
void init(const std::string& hostname, int port);
|
||||
|
||||
/**
|
||||
* Start TLS on this connection. This isn't in the constructor,
|
||||
|
|
@ -85,7 +85,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @param dn The name of the entry to bind as
|
||||
* @param passwd The cleartext password for the entry
|
||||
*/
|
||||
void bind(const string& dn="", const string& passwd="",
|
||||
void bind(const std::string& dn="", const std::string& passwd="",
|
||||
LDAPConstraints* cons=0);
|
||||
|
||||
/**
|
||||
|
|
@ -112,7 +112,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* attr-parameter matched an Attribute of the entry. false if it
|
||||
* did not match
|
||||
*/
|
||||
bool compare(const string& dn, const LDAPAttribute& attr,
|
||||
bool compare(const std::string& dn, const LDAPAttribute& attr,
|
||||
LDAPConstraints* cons=0);
|
||||
|
||||
/**
|
||||
|
|
@ -126,7 +126,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
void del(const string& dn, const LDAPConstraints* cons=0);
|
||||
void del(const std::string& dn, const LDAPConstraints* cons=0);
|
||||
|
||||
/**
|
||||
* Use this method to perform the ADD-operation
|
||||
|
|
@ -151,7 +151,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
void modify(const string& dn, const LDAPModList* mods,
|
||||
void modify(const std::string& dn, const LDAPModList* mods,
|
||||
const LDAPConstraints* cons=0);
|
||||
|
||||
/**
|
||||
|
|
@ -174,8 +174,8 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @param cons A set of constraints that should be used with this
|
||||
* request
|
||||
*/
|
||||
void rename(const string& dn, const string& newRDN,
|
||||
bool delOldRDN=false, const string& newParentDN="",
|
||||
void rename(const std::string& dn, const std::string& newRDN,
|
||||
bool delOldRDN=false, const std::string& newParentDN="",
|
||||
const LDAPConstraints* cons=0);
|
||||
|
||||
/**
|
||||
|
|
@ -190,7 +190,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* LDAPAsynConnection::SEARCH_BASE, <BR>
|
||||
* LDAPAsynConnection::SEARCH_ONE, <BR>
|
||||
* LDAPAsynConnection::SEARCH_SUB
|
||||
* @param filter The string representation of a search filter to
|
||||
* @param filter The std::string representation of a search filter to
|
||||
* use with this operation
|
||||
* @param attrsOnly true if only the attributes names (no values)
|
||||
* should be returned
|
||||
|
|
@ -199,8 +199,8 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @returns A pointer to a LDAPSearchResults-object that can be
|
||||
* used to read the results of the search.
|
||||
*/
|
||||
LDAPSearchResults* search(const string& base, int scope=0,
|
||||
const string& filter="objectClass=*",
|
||||
LDAPSearchResults* search(const std::string& base, int scope=0,
|
||||
const std::string& filter="objectClass=*",
|
||||
const StringList& attrs=StringList(), bool attrsOnly=false,
|
||||
const LDAPConstraints* cons=0);
|
||||
|
||||
|
|
@ -219,10 +219,10 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
* @returns The result of the Extended Operation as an
|
||||
* pointer to a LDAPExtResult-object.
|
||||
*/
|
||||
LDAPExtResult* extOperation(const string& oid, const string&
|
||||
LDAPExtResult* extOperation(const std::string& oid, const std::string&
|
||||
value="", const LDAPConstraints *const = 0);
|
||||
|
||||
const string& getHost() const;
|
||||
const std::string& getHost() const;
|
||||
|
||||
int getPort() const;
|
||||
|
||||
|
|
@ -240,7 +240,7 @@ class LDAPConnection : private LDAPAsynConnection {
|
|||
/// is cacheEnabled?
|
||||
bool getCacheEnabled();
|
||||
/// uncache a specific dn. Used internally by methods that write.
|
||||
void uncache_entry(string &dn);
|
||||
void uncache_entry(std::string &dn);
|
||||
/// used to clear the cache. Probably should be used after creating
|
||||
/// an object that a cached search should find.
|
||||
void flush_cache();
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@
|
|||
#include "LDAPConstraints.h"
|
||||
#include "LDAPControlSet.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPConstraints::LDAPConstraints(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPConstraints::LDAPConstraints()" << endl);
|
||||
m_aliasDeref=LDAPConstraints::DEREF_NEVER;
|
||||
|
|
|
|||
|
|
@ -26,10 +26,10 @@
|
|||
class LDAPConstraints{
|
||||
|
||||
public :
|
||||
const static int DEREF_NEVER = 0x00;
|
||||
const static int DEREF_SEARCHING = 0x01;
|
||||
const static int DEREF_FINDING = 0x02;
|
||||
const static int DEREF_ALWAYS = 0x04;
|
||||
static const int DEREF_NEVER = 0x00;
|
||||
static const int DEREF_SEARCHING = 0x01;
|
||||
static const int DEREF_FINDING = 0x02;
|
||||
static const int DEREF_ALWAYS = 0x04;
|
||||
|
||||
//* Constructs a LDAPConstraints object with default values
|
||||
LDAPConstraints();
|
||||
|
|
|
|||
|
|
@ -6,6 +6,9 @@
|
|||
|
||||
#include "LDAPControl.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPCtrl::LDAPCtrl(const LDAPCtrl& c){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPCtrl::LDAPCtrl(&)" << endl);
|
||||
m_oid=c.m_oid;
|
||||
|
|
|
|||
|
|
@ -38,8 +38,8 @@ class LDAPCtrl{
|
|||
* critical by the server.
|
||||
* @param data: If there is data for the control, put it here.
|
||||
*/
|
||||
LDAPCtrl(const string& oid, bool critical=false,
|
||||
const string& data=string());
|
||||
LDAPCtrl(const std::string& oid, bool critical=false,
|
||||
const std::string& data=std::string());
|
||||
|
||||
/**
|
||||
* Creates a copy of the Control that "ctrl is pointing to
|
||||
|
|
@ -54,12 +54,12 @@ class LDAPCtrl{
|
|||
/**
|
||||
* @return The OID of the control
|
||||
*/
|
||||
string getOID() const;
|
||||
std::string getOID() const;
|
||||
|
||||
/**
|
||||
* @return The Data of the control as a string-Objekt
|
||||
* @return The Data of the control as a std::string-Objekt
|
||||
*/
|
||||
string getData() const;
|
||||
std::string getData() const;
|
||||
|
||||
/**
|
||||
* @return "true" if the control is critical
|
||||
|
|
@ -75,8 +75,8 @@ class LDAPCtrl{
|
|||
LDAPControl* getControlStruct() const;
|
||||
|
||||
private :
|
||||
string m_oid;
|
||||
string m_data;
|
||||
std::string m_oid;
|
||||
std::string m_data;
|
||||
bool m_isCritical;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@
|
|||
#include "debug.h"
|
||||
#include "LDAPControlSet.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPControlSet::LDAPControlSet(){
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
#include <ldap.h>
|
||||
#include <LDAPControl.h>
|
||||
|
||||
typedef list<LDAPCtrl> CtrlList;
|
||||
typedef std::list<LDAPCtrl> CtrlList;
|
||||
|
||||
/**
|
||||
* This container class is used to store multiple LDAPCtrl-objects.
|
||||
|
|
@ -19,7 +19,7 @@ class LDAPControlSet {
|
|||
typedef CtrlList::const_iterator const_iterator;
|
||||
public :
|
||||
/**
|
||||
* Constructs an empty list
|
||||
* Constructs an empty std::list
|
||||
*/
|
||||
LDAPControlSet();
|
||||
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPMessageQueue.h"
|
||||
#include "LDAPResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPDeleteRequest::LDAPDeleteRequest( const LDAPDeleteRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ class LDAPMessageQueue;
|
|||
class LDAPDeleteRequest : public LDAPRequest{
|
||||
public :
|
||||
LDAPDeleteRequest(const LDAPDeleteRequest& req);
|
||||
LDAPDeleteRequest(const string& dn, LDAPAsynConnection *connect,
|
||||
LDAPDeleteRequest(const std::string& dn, LDAPAsynConnection *connect,
|
||||
const LDAPConstraints *cons, bool isReferral=false,
|
||||
const LDAPRequest* parent=0);
|
||||
virtual ~LDAPDeleteRequest();
|
||||
|
|
@ -20,6 +20,6 @@ class LDAPDeleteRequest : public LDAPRequest{
|
|||
virtual LDAPRequest* followReferral(LDAPMsg* refs);
|
||||
|
||||
private :
|
||||
string m_dn;
|
||||
std::string m_dn;
|
||||
};
|
||||
#endif //LDAP_DELETE_REQUEST_H
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@
|
|||
|
||||
#include "LDAPException.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPEntry::LDAPEntry(const LDAPEntry& entry){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPEntry::LDAPEntry(&)" << endl);
|
||||
m_dn=entry.m_dn;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ class LDAPEntry{
|
|||
* @param dn The Distinguished Name for the new entry.
|
||||
* @param attrs The attributes for the new entry.
|
||||
*/
|
||||
LDAPEntry(const string& dn=string(),
|
||||
LDAPEntry(const std::string& dn=std::string(),
|
||||
const LDAPAttributeList *attrs=new LDAPAttributeList());
|
||||
|
||||
/**
|
||||
|
|
@ -48,18 +48,18 @@ class LDAPEntry{
|
|||
* Sets the DN-attribute.
|
||||
* @param dn: The new DN for the entry.
|
||||
*/
|
||||
void setDN(const string& dn);
|
||||
void setDN(const std::string& dn);
|
||||
|
||||
/**
|
||||
* Sets the attributes of the entry.
|
||||
* @param attr: A pointer to a list of the new attributes.
|
||||
* @param attr: A pointer to a std::list of the new attributes.
|
||||
*/
|
||||
void setAttributes(LDAPAttributeList *attrs);
|
||||
|
||||
/**
|
||||
* @returns The current DN of the entry.
|
||||
*/
|
||||
const string getDN() const ;
|
||||
const std::string getDN() const ;
|
||||
|
||||
/**
|
||||
* @returns A const pointer to the attributes of the entry.
|
||||
|
|
@ -70,11 +70,11 @@ class LDAPEntry{
|
|||
* This method can be used to dump the data of a LDAPResult-Object.
|
||||
* It is only useful for debugging purposes at the moment
|
||||
*/
|
||||
friend ostream& operator << (ostream& s, const LDAPEntry& le);
|
||||
friend std::ostream& operator << (std::ostream& s, const LDAPEntry& le);
|
||||
|
||||
private :
|
||||
|
||||
LDAPAttributeList *m_attrs;
|
||||
string m_dn;
|
||||
std::string m_dn;
|
||||
};
|
||||
#endif //LDAP_ENTRY_H
|
||||
|
|
|
|||
|
|
@ -10,12 +10,12 @@
|
|||
|
||||
class LDAPEntry;
|
||||
|
||||
typedef list<LDAPEntry> EntryList;
|
||||
typedef std::list<LDAPEntry> EntryList;
|
||||
|
||||
/**
|
||||
* For internal use only.
|
||||
*
|
||||
* This class is used by LDAPSearchResults to store a list of
|
||||
* This class is used by LDAPSearchResults to store a std::list of
|
||||
* LDAPEntry-Objects
|
||||
*/
|
||||
class LDAPEntryList{
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
|
||||
#include "LDAPAsynConnection.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPException::LDAPException(int res_code, const string& err_string){
|
||||
m_res_code=res_code;
|
||||
m_res_string=string(ldap_err2string(res_code));
|
||||
|
|
|
|||
|
|
@ -22,10 +22,10 @@ class LDAPException{
|
|||
/**
|
||||
* Constructs a LDAPException-object from the parameters
|
||||
* @param res_code A valid LDAP result code.
|
||||
* @param err_string An addional error message for the error
|
||||
* @param err_std::string An addional error message for the error
|
||||
* that happend (optional)
|
||||
*/
|
||||
LDAPException(int res_code, const string& err_string=string());
|
||||
LDAPException(int res_code, const std::string& err_string=std::string());
|
||||
|
||||
/**
|
||||
* Constructs a LDAPException-object from the error state of a
|
||||
|
|
@ -50,22 +50,22 @@ class LDAPException{
|
|||
* @return The error message that is corresponding to the result
|
||||
* code .
|
||||
*/
|
||||
const string& getResultMsg() const;
|
||||
const std::string& getResultMsg() const;
|
||||
|
||||
/**
|
||||
* @return The addional error message of the error (if it was set)
|
||||
*/
|
||||
const string& getServerMsg() const;
|
||||
const std::string& getServerMsg() const;
|
||||
|
||||
/**
|
||||
* This method can be used to dump the data of a LDAPResult-Object.
|
||||
* It is only useful for debugging purposes at the moment
|
||||
*/
|
||||
friend ostream& operator << (ostream &s, LDAPException e);
|
||||
friend std::ostream& operator << (std::ostream &s, LDAPException e);
|
||||
|
||||
private :
|
||||
int m_res_code;
|
||||
string m_res_string;
|
||||
string m_err_string;
|
||||
std::string m_res_string;
|
||||
std::string m_err_string;
|
||||
};
|
||||
#endif //LDAP_EXCEPTION_H
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPException.h"
|
||||
#include "LDAPResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPExtRequest::LDAPExtRequest(const LDAPExtRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPExtRequest::LDAPExtRequest(&)" << endl);
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ class LDAPExtRequest : LDAPRequest {
|
|||
|
||||
public:
|
||||
LDAPExtRequest(const LDAPExtRequest& req);
|
||||
LDAPExtRequest(const string& oid, const string& data,
|
||||
LDAPExtRequest(const std::string& oid, const std::string& data,
|
||||
LDAPAsynConnection *connect, const LDAPConstraints *cons,
|
||||
bool isReferral=false, const LDAPRequest* parent=0);
|
||||
virtual ~LDAPExtRequest();
|
||||
|
|
@ -20,8 +20,8 @@ class LDAPExtRequest : LDAPRequest {
|
|||
virtual LDAPRequest* followReferral(LDAPMsg* urls);
|
||||
|
||||
private:
|
||||
string m_oid;
|
||||
string m_data;
|
||||
std::string m_oid;
|
||||
std::string m_data;
|
||||
};
|
||||
|
||||
#endif // LDAP_EXT_REQUEST_H
|
||||
|
|
|
|||
|
|
@ -11,6 +11,8 @@
|
|||
#include "LDAPResult.h"
|
||||
#include "LDAPExtResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPExtResult::LDAPExtResult(const LDAPRequest* req, LDAPMessage* msg) :
|
||||
LDAPResult(req, msg){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPExtResult::LDAPExtResult()" << endl);
|
||||
|
|
|
|||
|
|
@ -33,17 +33,17 @@ class LDAPExtResult : public LDAPResult {
|
|||
* @returns The OID of the Extended Operation that has returned
|
||||
* this result.
|
||||
*/
|
||||
const string& getResponseOid() const;
|
||||
const std::string& getResponseOid() const;
|
||||
|
||||
/**
|
||||
* @returns If the result contained data this method will return
|
||||
* the data to the caller as a string.
|
||||
* the data to the caller as a std::string.
|
||||
*/
|
||||
const string& getResponse() const;
|
||||
const std::string& getResponse() const;
|
||||
|
||||
private:
|
||||
string m_oid;
|
||||
string m_data;
|
||||
std::string m_oid;
|
||||
std::string m_data;
|
||||
};
|
||||
|
||||
#endif // LDAP_EXT_RESULT_H
|
||||
|
|
|
|||
|
|
@ -14,6 +14,8 @@
|
|||
#include "debug.h"
|
||||
#include <iostream>
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPMsg::LDAPMsg(LDAPMessage *msg){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPMsg::LDAPMsg()" << endl);
|
||||
msgType=ldap_msgtype(msg);
|
||||
|
|
|
|||
|
|
@ -18,6 +18,8 @@
|
|||
#include "LDAPUrlList.h"
|
||||
#include "LDAPException.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
// TODO: How to handle unsolicited notifications, like notice of
|
||||
// disconnection
|
||||
|
||||
|
|
|
|||
|
|
@ -16,8 +16,8 @@ class LDAPMsg;
|
|||
class LDAPRequest;
|
||||
class LDAPSearchRequest;
|
||||
class LDAPUrl;
|
||||
typedef stack<LDAPRequest*> LDAPRequestStack;
|
||||
typedef list<LDAPRequest*> LDAPRequestList;
|
||||
typedef std::stack<LDAPRequest*> LDAPRequestStack;
|
||||
typedef std::list<LDAPRequest*> LDAPRequestList;
|
||||
|
||||
/**
|
||||
* This class is created for the asynchronous LDAP-operations. And can be
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPResult.h"
|
||||
#include "LDAPUrlList.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPModDNRequest::LDAPModDNRequest(const LDAPModDNRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
|
|
|
|||
|
|
@ -12,8 +12,8 @@ class LDAPModDNRequest : LDAPRequest {
|
|||
|
||||
public:
|
||||
LDAPModDNRequest(const LDAPModDNRequest& req);
|
||||
LDAPModDNRequest(const string& dn, const string& newRDN,
|
||||
bool deleteOld, const string& newParentDN,
|
||||
LDAPModDNRequest(const std::string& dn, const std::string& newRDN,
|
||||
bool deleteOld, const std::string& newParentDN,
|
||||
LDAPAsynConnection *connect, const LDAPConstraints *cons,
|
||||
bool isReferral=false, const LDAPRequest* parent=0);
|
||||
virtual ~LDAPModDNRequest();
|
||||
|
|
@ -22,9 +22,9 @@ class LDAPModDNRequest : LDAPRequest {
|
|||
virtual LDAPRequest* followReferral(LDAPMsg* urls);
|
||||
|
||||
private:
|
||||
string m_dn;
|
||||
string m_newRDN;
|
||||
string m_newParentDN;
|
||||
std::string m_dn;
|
||||
std::string m_newRDN;
|
||||
std::string m_newParentDN;
|
||||
bool m_deleteOld;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,8 @@
|
|||
#include "LDAPModList.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPModList::LDAPModList(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPModList::LDAPModList()" << endl);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
#include <list>
|
||||
#include <LDAPModification.h>
|
||||
|
||||
typedef list<LDAPModification> ModList;
|
||||
typedef std::list<LDAPModification> ModList;
|
||||
|
||||
/**
|
||||
* This container class is used to store multiple LDAPModification-objects.
|
||||
|
|
@ -20,7 +20,7 @@ class LDAPModList{
|
|||
|
||||
public :
|
||||
/**
|
||||
* Constructs an empty list.
|
||||
* Constructs an empty std::list.
|
||||
*/
|
||||
LDAPModList();
|
||||
|
||||
|
|
@ -30,13 +30,13 @@ class LDAPModList{
|
|||
LDAPModList(const LDAPModList&);
|
||||
|
||||
/**
|
||||
* Adds one element to the end of the list.
|
||||
* @param mod The LDAPModification to add to the list.
|
||||
* Adds one element to the end of the std::list.
|
||||
* @param mod The LDAPModification to add to the std::list.
|
||||
*/
|
||||
void addModification(const LDAPModification &mod);
|
||||
|
||||
/**
|
||||
* Translates the list to a 0-terminated array of
|
||||
* Translates the std::list to a 0-terminated array of
|
||||
* LDAPMod-structures as needed by the C-API
|
||||
*/
|
||||
LDAPMod** toLDAPModArray();
|
||||
|
|
|
|||
|
|
@ -7,6 +7,8 @@
|
|||
#include "LDAPModification.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPModification::LDAPModification(const LDAPAttribute& attr, mod_op op){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPModification::LDAPModification()" << endl);
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT | LDAP_DEBUG_PARAMETER,
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPMessageQueue.h"
|
||||
#include "LDAPResult.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPModifyRequest::LDAPModifyRequest(const LDAPModifyRequest& req) :
|
||||
LDAPRequest(req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
|
|
|
|||
|
|
@ -12,12 +12,12 @@ class LDAPMessageQueue;
|
|||
|
||||
class LDAPModifyRequest : LDAPRequest {
|
||||
private :
|
||||
string m_dn;
|
||||
std::string m_dn;
|
||||
LDAPModList *m_modList;
|
||||
|
||||
public:
|
||||
LDAPModifyRequest(const LDAPModifyRequest& mod);
|
||||
LDAPModifyRequest(const string& dn, const LDAPModList *modList,
|
||||
LDAPModifyRequest(const std::string& dn, const LDAPModList *modList,
|
||||
LDAPAsynConnection *connect, const LDAPConstraints *cons,
|
||||
bool isReferral=false, const LDAPRequest* req=0);
|
||||
virtual ~LDAPModifyRequest();
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
class LDAPRebind{
|
||||
public:
|
||||
virtual ~LDAPRebind() {}
|
||||
virtual LDAPRebindAuth* getRebindAuth(const string& hostname,
|
||||
virtual LDAPRebindAuth* getRebindAuth(const std::string& hostname,
|
||||
int port) const = 0;
|
||||
};
|
||||
#endif //LDAP_REBIND_H
|
||||
|
|
|
|||
|
|
@ -8,6 +8,8 @@
|
|||
#include "LDAPRebindAuth.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPRebindAuth::LDAPRebindAuth(const string& dn, const string& pwd){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPRebindAuth::LDAPRebindAuth()" << endl);
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT | LDAP_DEBUG_PARAMETER," dn:" << dn << endl
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ class LDAPRebindAuth{
|
|||
* @param dn The DN that should be used for the authentication
|
||||
* @param pwd The password that belongs to the DN
|
||||
*/
|
||||
LDAPRebindAuth(const string& dn="", const string& pwd="");
|
||||
LDAPRebindAuth(const std::string& dn="", const std::string& pwd="");
|
||||
|
||||
/**
|
||||
* Copy-constructor
|
||||
|
|
@ -38,16 +38,16 @@ class LDAPRebindAuth{
|
|||
/**
|
||||
* @return The DN that was set in the constructor
|
||||
*/
|
||||
const string& getDN() const;
|
||||
const std::string& getDN() const;
|
||||
|
||||
/**
|
||||
* @return The password that was set in the constructor
|
||||
*/
|
||||
const string& getPassword() const;
|
||||
const std::string& getPassword() const;
|
||||
|
||||
private:
|
||||
string m_dn;
|
||||
string m_password;
|
||||
std::string m_dn;
|
||||
std::string m_password;
|
||||
};
|
||||
|
||||
#endif //LDAP_REBIND_AUTH_H
|
||||
|
|
|
|||
|
|
@ -10,10 +10,10 @@
|
|||
|
||||
class LDAPSearchReference;
|
||||
|
||||
typedef list<LDAPSearchReference> RefList;
|
||||
typedef std::list<LDAPSearchReference> RefList;
|
||||
|
||||
/**
|
||||
* Container class for storing a list of Search References
|
||||
* Container class for storing a std::list of Search References
|
||||
*
|
||||
* Used internally only by LDAPSearchResults
|
||||
*/
|
||||
|
|
@ -22,7 +22,7 @@ class LDAPReferenceList{
|
|||
typedef RefList::const_iterator const_iterator;
|
||||
|
||||
/**
|
||||
* Constructs an empty list.
|
||||
* Constructs an empty std::list.
|
||||
*/
|
||||
LDAPReferenceList();
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ class LDAPReferralException : public LDAPException{
|
|||
|
||||
public :
|
||||
/**
|
||||
* Creates an object that is initialized with a list of URLs
|
||||
* Creates an object that is initialized with a std::list of URLs
|
||||
*/
|
||||
LDAPReferralException(const LDAPUrlList& urls);
|
||||
|
||||
|
|
|
|||
|
|
@ -7,6 +7,8 @@
|
|||
#include "debug.h"
|
||||
#include "LDAPRequest.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPRequest::LDAPRequest(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT, "LDAPRequest::LDAPRequest()" << endl);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,8 @@
|
|||
#include "LDAPRequest.h"
|
||||
#include "LDAPException.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPResult::LDAPResult(const LDAPRequest *req, LDAPMessage *msg) :
|
||||
LDAPMsg(msg){
|
||||
if(msg != 0){
|
||||
|
|
|
|||
|
|
@ -118,16 +118,16 @@ class LDAPResult : public LDAPMsg{
|
|||
/**
|
||||
* This method transforms the result code to a human-readable
|
||||
* result message.
|
||||
* @returns A string containing the result message.
|
||||
* @returns A std::string containing the result message.
|
||||
*/
|
||||
string resToString() const;
|
||||
std::string resToString() const;
|
||||
|
||||
/**
|
||||
* In some case of error the server may return addional error
|
||||
* messages.
|
||||
* @returns The additional error message returned by the server.
|
||||
*/
|
||||
const string& getErrMsg() const;
|
||||
const std::string& getErrMsg() const;
|
||||
|
||||
/**
|
||||
* For messages with a result code of: NO_SUCH_OBJECT,
|
||||
|
|
@ -136,7 +136,7 @@ class LDAPResult : public LDAPMsg{
|
|||
* be found for this operation.
|
||||
* @returns The Matched-DN value that was returned by the server.
|
||||
*/
|
||||
const string& getMatchedDN() const;
|
||||
const std::string& getMatchedDN() const;
|
||||
|
||||
/**
|
||||
* @returns If the result code is REFERRAL this methode returns the
|
||||
|
|
@ -146,15 +146,15 @@ class LDAPResult : public LDAPMsg{
|
|||
|
||||
private :
|
||||
int m_resCode;
|
||||
string m_matchedDN;
|
||||
string m_errMsg;
|
||||
std::string m_matchedDN;
|
||||
std::string m_errMsg;
|
||||
LDAPUrlList m_referrals;
|
||||
|
||||
/**
|
||||
* This method can be used to dump the data of a LDAPResult-Object.
|
||||
* It is only useful for debugging purposes at the moment
|
||||
*/
|
||||
friend ostream& operator<<(ostream &s,LDAPResult &l);
|
||||
friend std::ostream& operator<<(std::ostream &s,LDAPResult &l);
|
||||
};
|
||||
#endif //LDAP_RESULT_H
|
||||
|
||||
|
|
|
|||
|
|
@ -12,6 +12,8 @@
|
|||
#include "LDAPRequest.h"
|
||||
#include "LDAPUrl.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPSearchReference::LDAPSearchReference(const LDAPRequest *req,
|
||||
LDAPMessage *msg) : LDAPMsg(msg){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
|
|
|
|||
|
|
@ -13,6 +13,8 @@
|
|||
#include "LDAPRequest.h"
|
||||
#include "LDAPUrl.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPSearchRequest::LDAPSearchRequest(const LDAPSearchRequest& req ) :
|
||||
LDAPRequest (req){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ class LDAPSearchRequest : public LDAPRequest{
|
|||
public :
|
||||
LDAPSearchRequest(const LDAPSearchRequest& req);
|
||||
|
||||
LDAPSearchRequest(const string& base, int scope, const string& filter,
|
||||
LDAPSearchRequest(const std::string& base, int scope, const std::string& filter,
|
||||
const StringList& attrs, bool attrsOnly,
|
||||
LDAPAsynConnection *connect,
|
||||
const LDAPConstraints* cons, bool isReferral=false,
|
||||
|
|
@ -29,9 +29,9 @@ class LDAPSearchRequest : public LDAPRequest{
|
|||
virtual bool equals(const LDAPRequest* req) const;
|
||||
|
||||
private :
|
||||
string m_base;
|
||||
std::string m_base;
|
||||
int m_scope;
|
||||
string m_filter;
|
||||
std::string m_filter;
|
||||
StringList m_attrs;
|
||||
bool m_attrsOnly;
|
||||
|
||||
|
|
|
|||
|
|
@ -10,9 +10,12 @@
|
|||
#include "LDAPSearchResult.h"
|
||||
#include "LDAPRequest.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPSearchResult::LDAPSearchResult(const LDAPRequest *req,
|
||||
LDAPMessage *msg) : LDAPMsg(msg){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,"LDAPSearchResult::LDAPSearchResult()" << endl);
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT,
|
||||
"LDAPSearchResult::LDAPSearchResult()" << endl);
|
||||
entry = new LDAPEntry(req->getConnection(), msg);
|
||||
//retrieve the controls here
|
||||
LDAPControl** srvctrls=0;
|
||||
|
|
|
|||
|
|
@ -9,6 +9,8 @@
|
|||
#include <ldap.h>
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPUrl::LDAPUrl(const char *url){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT, "LDAPUrl::LDAPUrl()" << endl);
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT | LDAP_DEBUG_PARAMETER,
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ class LDAPUrl{
|
|||
|
||||
public :
|
||||
/**
|
||||
* Create a new object from a c-string that contains a LDAP-Url
|
||||
* Create a new object from a c-std::string that contains a LDAP-Url
|
||||
*/
|
||||
LDAPUrl(const char *url);
|
||||
|
||||
|
|
@ -43,25 +43,25 @@ class LDAPUrl{
|
|||
int getScope() const;
|
||||
|
||||
/**
|
||||
* @return The complete URL as a string
|
||||
* @return The complete URL as a std::string
|
||||
*/
|
||||
const string& getURLString() const;
|
||||
const std::string& getURLString() const;
|
||||
|
||||
/**
|
||||
* @return The hostname or IP-Address of the destination host.
|
||||
*/
|
||||
const string& getHost() const;
|
||||
const std::string& getHost() const;
|
||||
|
||||
/**
|
||||
* @return The Base-DN part of the URL
|
||||
*/
|
||||
const string& getDN() const;
|
||||
const std::string& getDN() const;
|
||||
|
||||
|
||||
/**
|
||||
* @return The Filter part of the URL
|
||||
*/
|
||||
const string& getFilter() const;
|
||||
const std::string& getFilter() const;
|
||||
|
||||
/**
|
||||
* @return The List of attributes that was in the URL
|
||||
|
|
@ -71,12 +71,12 @@ class LDAPUrl{
|
|||
protected :
|
||||
int m_Port;
|
||||
int m_Scope;
|
||||
string m_Host;
|
||||
string m_DN;
|
||||
string m_Filter;
|
||||
std::string m_Host;
|
||||
std::string m_DN;
|
||||
std::string m_Filter;
|
||||
StringList m_Attrs;
|
||||
LDAPURLDesc *m_urlDesc;
|
||||
string m_urlString;
|
||||
std::string m_urlString;
|
||||
};
|
||||
|
||||
#endif //LDAP_URL_H
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@
|
|||
#include "LDAPUrlList.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
LDAPUrlList::LDAPUrlList(){
|
||||
DEBUG(LDAP_DEBUG_CONSTRUCT," LDAPUrlList::LDAPUrlList()" << endl);
|
||||
m_urls=UrlList();
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
#include <list>
|
||||
#include <LDAPUrl.h>
|
||||
|
||||
typedef list<LDAPUrl> UrlList;
|
||||
typedef std::list<LDAPUrl> UrlList;
|
||||
|
||||
/**
|
||||
* This container class is used to store multiple LDAPUrl-objects.
|
||||
|
|
@ -19,7 +19,7 @@ class LDAPUrlList{
|
|||
typedef UrlList::const_iterator const_iterator;
|
||||
|
||||
/**
|
||||
* Constructs an empty list.
|
||||
* Constructs an empty std::list.
|
||||
*/
|
||||
LDAPUrlList();
|
||||
|
||||
|
|
@ -32,7 +32,7 @@ class LDAPUrlList{
|
|||
* For internal use only
|
||||
*
|
||||
* This constructor is used by the library internally to create a
|
||||
* list of URLs from a array of C-strings that was return by
|
||||
* std::list of URLs from a array of C-std::strings that was return by
|
||||
* the C-API
|
||||
*/
|
||||
LDAPUrlList(char** urls);
|
||||
|
|
|
|||
|
|
@ -47,6 +47,7 @@ include_HEADERS = LDAPAsynConnection.h \
|
|||
LDAPConnection.h \
|
||||
LDAPConstraints.h \
|
||||
LDAPControl.h \
|
||||
LDAPControlSet.h \
|
||||
LDAPEntry.h \
|
||||
LDAPEntryList.h \
|
||||
LDAPException.h \
|
||||
|
|
@ -62,6 +63,7 @@ include_HEADERS = LDAPAsynConnection.h \
|
|||
LDAPResult.h \
|
||||
LDAPSearchReference.h \
|
||||
LDAPSearchResult.h \
|
||||
LDAPSearchResults.h \
|
||||
LDAPUrl.h \
|
||||
LDAPUrlList.h \
|
||||
StringList.h
|
||||
|
|
|
|||
|
|
@ -79,7 +79,7 @@ lib_LTLIBRARIES = libldapcpp.la
|
|||
libldapcpp_la_SOURCES = LDAPAddRequest.cpp LDAPAsynConnection.cpp LDAPAttribute.cpp LDAPAttributeList.cpp LDAPBindRequest.cpp LDAPCompareRequest.cpp LDAPConnection.cpp LDAPConstraints.cpp LDAPControl.cpp LDAPControlSet.cpp LDAPDeleteRequest.cpp LDAPEntry.cpp LDAPEntryList.cpp LDAPException.cpp LDAPExtRequest.cpp LDAPExtResult.cpp LDAPMessage.cpp LDAPMessageQueue.cpp LDAPModDNRequest.cpp LDAPModification.cpp LDAPModifyRequest.cpp LDAPModList.cpp LDAPRebind.cpp LDAPRebindAuth.cpp LDAPReferralException.cpp LDAPReferenceList.cpp LDAPRequest.cpp LDAPResult.cpp LDAPSearchReference.cpp LDAPSearchRequest.cpp LDAPSearchResult.cpp LDAPSearchResults.cpp LDAPUrl.cpp LDAPUrlList.cpp StringList.cpp
|
||||
|
||||
|
||||
include_HEADERS = LDAPAsynConnection.h LDAPAttribute.h LDAPAttributeList.h LDAPConnection.h LDAPConstraints.h LDAPControl.h LDAPEntry.h LDAPEntryList.h LDAPException.h LDAPExtResult.h LDAPMessage.h LDAPMessageQueue.h LDAPModification.h LDAPModList.h LDAPRebind.h LDAPRebindAuth.h LDAPReferralException.h LDAPReferenceList.h LDAPResult.h LDAPSearchReference.h LDAPSearchResult.h LDAPUrl.h LDAPUrlList.h StringList.h
|
||||
include_HEADERS = LDAPAsynConnection.h LDAPAttribute.h LDAPAttributeList.h LDAPConnection.h LDAPConstraints.h LDAPControl.h LDAPControlSet.h LDAPEntry.h LDAPEntryList.h LDAPException.h LDAPExtResult.h LDAPMessage.h LDAPMessageQueue.h LDAPModification.h LDAPModList.h LDAPRebind.h LDAPRebindAuth.h LDAPReferralException.h LDAPReferenceList.h LDAPResult.h LDAPSearchReference.h LDAPSearchResult.h LDAPSearchResults.h LDAPUrl.h LDAPUrlList.h StringList.h
|
||||
|
||||
|
||||
noinst_HEADERS = LDAPAddRequest.h LDAPBindRequest.h LDAPCompareRequest.h LDAPDeleteRequest.h LDAPExtRequest.h LDAPModDNRequest.h LDAPModifyRequest.h LDAPRequest.h LDAPSearchRequest.h
|
||||
|
|
@ -322,7 +322,7 @@ distdir: $(DISTFILES)
|
|||
@for file in $(DISTFILES); do \
|
||||
d=$(srcdir); \
|
||||
if test -d $$d/$$file; then \
|
||||
cp -pr $$/$$file $(distdir)/$$file; \
|
||||
cp -pr $$d/$$file $(distdir)/$$file; \
|
||||
else \
|
||||
test -f $(distdir)/$$file \
|
||||
|| ln $$d/$$file $(distdir)/$$file 2> /dev/null \
|
||||
|
|
|
|||
|
|
@ -6,6 +6,8 @@
|
|||
#include "StringList.h"
|
||||
#include "debug.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
StringList::StringList(){
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -8,10 +8,10 @@
|
|||
|
||||
#include <string>
|
||||
#include <list>
|
||||
typedef list<string> ListType;
|
||||
typedef std::list<std::string> ListType;
|
||||
|
||||
/**
|
||||
* Container class to store multiple string-objects
|
||||
* Container class to store multiple std::string-objects
|
||||
*/
|
||||
class StringList{
|
||||
private:
|
||||
|
|
@ -21,7 +21,7 @@ class StringList{
|
|||
typedef ListType::const_iterator const_iterator;
|
||||
|
||||
/**
|
||||
* Constructs an empty list.
|
||||
* Constructs an empty std::list.
|
||||
*/
|
||||
StringList();
|
||||
|
||||
|
|
@ -34,7 +34,7 @@ class StringList{
|
|||
* For internal use only
|
||||
*
|
||||
* This constructor is used by the library internally to create a
|
||||
* list of string from a array for c-Strings (char*)thar was
|
||||
* std::list of std::string from a array for c-Strings (char*)thar was
|
||||
* returned by the C-API
|
||||
*/
|
||||
StringList(char** values);
|
||||
|
|
@ -54,7 +54,7 @@ class StringList{
|
|||
* Adds one element to the end of the list.
|
||||
* @param attr The attribute to add to the list.
|
||||
*/
|
||||
void add(const string& value);
|
||||
void add(const std::string& value);
|
||||
|
||||
/**
|
||||
* @return The number of strings that are currently
|
||||
|
|
|
|||
|
|
@ -17,12 +17,12 @@
|
|||
#define DEBUGLEVEL LDAP_DEBUG_ANY
|
||||
|
||||
#define PRINT_FILE \
|
||||
cerr << "file: " __FILE__ << " line: " << __LINE__
|
||||
std::cerr << "file: " __FILE__ << " line: " << __LINE__
|
||||
|
||||
#ifdef WITH_DEBUG
|
||||
#define DEBUG(level, arg) \
|
||||
if((level) & DEBUGLEVEL){ \
|
||||
cerr << arg ; \
|
||||
std::cerr << arg ; \
|
||||
}
|
||||
#else
|
||||
#undef DEBUG
|
||||
|
|
|
|||
Loading…
Reference in a new issue