]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
more autoconf changes
authorKurt Zeilenga <kurt@openldap.org>
Thu, 13 Aug 1998 20:23:30 +0000 (20:23 +0000)
committerKurt Zeilenga <kurt@openldap.org>
Thu, 13 Aug 1998 20:23:30 +0000 (20:23 +0000)
28 files changed:
Makefile.in
aclocal.m4
clients/ud/main.c
clients/ud/util.c
configure
configure.in
contrib/saucer/Make-template [deleted file]
contrib/whois++/Makefile [deleted file]
include/bridge.h
include/ldapconfig.h.in
include/portable.h.bot
include/portable.h.in
libraries/liblber/decode.c
libraries/liblber/encode.c
servers/slapd/tools/Makefile.in
servers/slapd/tools/centipede.c
servers/slapd/tools/chlog2replog.c
servers/slapd/tools/edb2ldif.c
servers/slapd/tools/ldapsyntax.c
servers/slapd/tools/ldbmcat.c
servers/slapd/tools/ldbmtest.c
servers/slapd/tools/ldif.c
servers/slapd/tools/ldif2id2children.c
servers/slapd/tools/ldif2id2entry.c
servers/slapd/tools/ldif2index.c
servers/slapd/tools/ldif2ldbm.c
servers/slapd/tools/sizecount.c
tests/Make-template [deleted file]

index bebe3e52b4f36697cef99a712cb600a7134c8ce9..d1e93e7cccfc56f595684cf0e86a42db52a60f33 100644 (file)
@@ -2,5 +2,24 @@
 # Copyright 1998 Net Boolean Incorporated
 # COPYING RESTRICTIONS APPLY, See COPYING file
 
-SUBDIRS= include libraries clients servers
+SUBDIRS= include libraries clients contrib servers
+
+makefiles:     FORCE
+       ./config.status
+
+configure: configure.in aclocal.m4
+       autoconf
+
+# autoheader might not change config.h.in, so touch a stamp file
+${srcdir}/include/portable.h.in:       stamp-h.in
+${srcdir}/stamp-h.in: configure.in aclocal.m4 acconfig.h
+       cd ${srcdir} && autoheader
+       @echo timestamp > ${srcdir}/stamp-h.in
+
+config.h: stamp-h
+stamp-h: config.h.in config.status
+       ./config.status
+
+config.status: configure
+       ./config.status --recheck
 
index 1c2d16438e3acb0d2cb6458b4dd532464fc91397..bc90b3559824b134ea41afde04ed50183b7b8ab8 100644 (file)
@@ -1,3 +1,4 @@
+dnl --------------------------------------------------------------------
 dnl Restricted form of AC_ARG_ENABLE that ensures user doesn't give bogus
 dnl values.
 dnl
@@ -18,12 +19,7 @@ ifelse($3,,[    :]dnl
   $4
 ])dnl
   ])])dnl
-dnl
-dnl Allow user to disable a normally-on option.
-dnl
-dnl AC_DEFUN([CF_ARG_DISABLE],[CF_ARG_OPTION($1,[$2 (default: on)],[$3],[$4],yes))dnl
-dnl
-dnl
+dnl --------------------------------------------------------------------
 dnl Check for declaration of sys_errlist in one of stdio.h and errno.h.
 dnl Declaration of sys_errlist on BSD4.4 interferes with our declaration.
 dnl Reported by Keith Bostic.
index cb2030c2833505a62e163df2509bae5d9f2fa734..c0b70b2ceb808d8cc058f34727de512cfe29f36e 100644 (file)
@@ -16,6 +16,8 @@
  *     Simon Fraser University, Academic Computing Services
  */
 
+#include "portable.h"
+
 #include <stdio.h>
 #include <sys/types.h>
 #if defined(NeXT)
@@ -43,7 +45,9 @@
 #include <lber.h>
 #include <ldap.h>
 #include <ldapconfig.h>
-#include "portable.h"
+
+#include "bridge.h"
+
 #include "ud.h"
 
 #ifndef lint
@@ -722,3 +726,22 @@ SIG_FN chwinsz()
        (void) signal(SIGWINCH, chwinsz);
 }
 #endif
+
+#if defined(NO_CACHE)
+
+void ldap_uncache_entry( LDAP *ld, char *dn )
+{
+
+}
+
+int ldap_enable_cache( LDAP *ld, long timeout, long maxmem )
+{
+  return 0;
+}
+
+void ldap_flush_cache( LDAP *ld )
+{
+
+}
+
+#endif /* NO_CACHE */
index 2edb5aa265903c9be92d107413b5e0ee183610fd..18b694b9c442da89a094e631eb2ec5d212890937 100644 (file)
  * is provided ``as is'' without express or implied warranty.
  */
 
+#include "portable.h"
+
 #include <stdio.h>
 #include <signal.h>
-#include <string.h>
+#include "ldap_string.h"
 #ifdef DOS
 #include <malloc.h>
 #endif
 #include <lber.h>
 #include <ldap.h>
 #include <ldapconfig.h>
-#if !defined(DOS) && !defined( VMS)
+#if !defined(DOS) && !defined(VMS)
 #include <sys/types.h>
 #endif
-#include "portable.h"
+
 #ifdef USE_TERMIOS
 #include <termios.h>
 #else /* USE_TERMIOS */
@@ -36,6 +38,8 @@
 #endif /* USE_TERMIOS */
 #include "ud.h"
 
+#include "bridge.h"
+
 #if defined(VMS)
 #define getch getchar
 #endif
@@ -226,8 +230,6 @@ FILE *where;
 fatal(s)
 char *s;
 {
-       void exit();
-
        if (errno != 0)
                perror(s);
 #ifdef KERBEROS
index c31d728c02dd0770d0e97da0b4c76c17bc364192..1bf8c4f4476c8d73c279fa948e2ba9d465fda83c 100755 (executable)
--- a/configure
+++ b/configure
 done
 
 
-echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2127: checking for working const" >&5
-if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
+echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
+echo "configure:2127: checking for uid_t in sys/types.h" >&5
+if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
 #line 2132 "configure"
 #include "confdefs.h"
+#include <sys/types.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "uid_t" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_uid_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_uid_t=no
+fi
+rm -f conftest*
 
-int main() {
+fi
 
-/* Ultrix mips cc rejects this.  */
-typedef int charset[2]; const charset x;
-/* SunOS 4.1.1 cc rejects this.  */
-char const *const *ccp;
-char **p;
-/* NEC SVR4.0.2 mips cc rejects this.  */
-struct point {int x, y;};
-static struct point const zero = {0,0};
-/* AIX XL C 1.02.0.0 rejects this.
-   It does not let you subtract one const X* pointer from another in an arm
-   of an if-expression whose if-part is not a constant expression */
-const char *g = "string";
-ccp = &g + (g ? g-g : 0);
-/* HPUX 7.0 cc rejects these. */
-++ccp;
-p = (char**) ccp;
-ccp = (char const *const *) p;
-{ /* SCO 3.2v4 cc rejects this.  */
-  char *t;
-  char const *s = 0 ? (char *) 0 : (char const *) 0;
+echo "$ac_t""$ac_cv_type_uid_t" 1>&6
+if test $ac_cv_type_uid_t = no; then
+  cat >> confdefs.h <<\EOF
+#define uid_t int
+EOF
 
-  *t++ = 0;
-}
-{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
-  int x[] = {25, 17};
-  const int *foo = &x[0];
-  ++foo;
-}
-{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
-  typedef const int *iptr;
-  iptr p = 0;
-  ++p;
-}
-{ /* AIX XL C 1.02.0.0 rejects this saying
-     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
-  struct s { int j; const int *ap[3]; };
-  struct s *b; b->j = 5;
-}
-{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
-  const int foo = 10;
+  cat >> confdefs.h <<\EOF
+#define gid_t int
+EOF
+
+fi
+
+echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
+echo "configure:2161: checking type of array argument to getgroups" >&5
+if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test "$cross_compiling" = yes; then
+  ac_cv_type_getgroups=cross
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2169 "configure"
+#include "confdefs.h"
+
+/* Thanks to Mike Rendell for this test.  */
+#include <sys/types.h>
+#define NGID 256
+#undef MAX
+#define MAX(x, y) ((x) > (y) ? (x) : (y))
+main()
+{
+  gid_t gidset[NGID];
+  int i, n;
+  union { gid_t gval; long lval; }  val;
+
+  val.lval = -1;
+  for (i = 0; i < NGID; i++)
+    gidset[i] = val.gval;
+  n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
+                 gidset);
+  /* Exit non-zero if getgroups seems to require an array of ints.  This
+     happens when gid_t is short but getgroups modifies an array of ints.  */
+  exit ((n > 0 && gidset[n] != val.gval) ? 1 : 0);
 }
 
-; return 0; }
 EOF
-if { (eval echo configure:2181: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-  rm -rf conftest*
-  ac_cv_c_const=yes
+if { (eval echo configure:2194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+then
+    ac_cv_type_getgroups=gid_t
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
+  rm -fr conftest*
+  ac_cv_type_getgroups=int
+fi
+rm -fr conftest*
+fi
+
+if test $ac_cv_type_getgroups = cross; then
+        cat > conftest.$ac_ext <<EOF
+#line 2208 "configure"
+#include "confdefs.h"
+#include <unistd.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "getgroups.*int.*gid_t" >/dev/null 2>&1; then
   rm -rf conftest*
-  ac_cv_c_const=no
+  ac_cv_type_getgroups=gid_t
+else
+  rm -rf conftest*
+  ac_cv_type_getgroups=int
 fi
 rm -f conftest*
+
+fi
 fi
 
-echo "$ac_t""$ac_cv_c_const" 1>&6
-if test $ac_cv_c_const = no; then
-  cat >> confdefs.h <<\EOF
-#define const 
+echo "$ac_t""$ac_cv_type_getgroups" 1>&6
+cat >> confdefs.h <<EOF
+#define GETGROUPS_T $ac_cv_type_getgroups
 EOF
 
-fi
 
-echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:2202: checking for uid_t in sys/types.h" >&5
-if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
+echo $ac_n "checking for mode_t""... $ac_c" 1>&6
+echo "configure:2232: checking for mode_t" >&5
+if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2207 "configure"
+#line 2237 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
+#if STDC_HEADERS
+#include <stdlib.h>
+#include <stddef.h>
+#endif
 EOF
 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
-  egrep "uid_t" >/dev/null 2>&1; then
+  egrep "mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
   rm -rf conftest*
-  ac_cv_type_uid_t=yes
+  ac_cv_type_mode_t=yes
 else
   rm -rf conftest*
-  ac_cv_type_uid_t=no
+  ac_cv_type_mode_t=no
 fi
 rm -f conftest*
 
 fi
-
-echo "$ac_t""$ac_cv_type_uid_t" 1>&6
-if test $ac_cv_type_uid_t = no; then
+echo "$ac_t""$ac_cv_type_mode_t" 1>&6
+if test $ac_cv_type_mode_t = no; then
   cat >> confdefs.h <<\EOF
-#define uid_t int
-EOF
-
-  cat >> confdefs.h <<\EOF
-#define gid_t int
+#define mode_t int
 EOF
 
 fi
 
 echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2236: checking for off_t" >&5
+echo "configure:2265: checking for off_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2241 "configure"
+#line 2270 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -2265,12 +2294,12 @@ EOF
 fi
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:2269: checking for pid_t" >&5
+echo "configure:2298: checking for pid_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2274 "configure"
+#line 2303 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -2297,13 +2326,54 @@ EOF
 
 fi
 
+echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
+echo "configure:2331: checking return type of signal handlers" >&5
+if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2336 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+#include <signal.h>
+#ifdef signal
+#undef signal
+#endif
+#ifdef __cplusplus
+extern "C" void (*signal (int, void (*)(int)))(int);
+#else
+void (*signal ()) ();
+#endif
+
+int main() {
+int i;
+; return 0; }
+EOF
+if { (eval echo configure:2353: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_type_signal=void
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_type_signal=int
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_type_signal" 1>&6
+cat >> confdefs.h <<EOF
+#define RETSIGTYPE $ac_cv_type_signal
+EOF
+
+
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2302: checking for size_t" >&5
+echo "configure:2372: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2307 "configure"
+#line 2377 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -2330,13 +2400,47 @@ EOF
 
 fi
 
+echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
+echo "configure:2405: checking for uid_t in sys/types.h" >&5
+if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2410 "configure"
+#include "confdefs.h"
+#include <sys/types.h>
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+  egrep "uid_t" >/dev/null 2>&1; then
+  rm -rf conftest*
+  ac_cv_type_uid_t=yes
+else
+  rm -rf conftest*
+  ac_cv_type_uid_t=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_type_uid_t" 1>&6
+if test $ac_cv_type_uid_t = no; then
+  cat >> confdefs.h <<\EOF
+#define uid_t int
+EOF
+
+  cat >> confdefs.h <<\EOF
+#define gid_t int
+EOF
+
+fi
+
 echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
-echo "configure:2335: checking for st_blksize in struct stat" >&5
+echo "configure:2439: checking for st_blksize in struct stat" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2340 "configure"
+#line 2444 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -2344,7 +2448,7 @@ int main() {
 struct stat s; s.st_blksize;
 ; return 0; }
 EOF
-if { (eval echo configure:2348: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2452: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_st_blksize=yes
 else
@@ -2365,12 +2469,12 @@ EOF
 fi
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:2369: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:2473: 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 2374 "configure"
+#line 2478 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -2379,7 +2483,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:2383: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -2400,12 +2504,12 @@ EOF
 fi
 
 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
-echo "configure:2404: checking whether struct tm is in sys/time.h or time.h" >&5
+echo "configure:2508: checking whether struct tm is in sys/time.h or time.h" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2409 "configure"
+#line 2513 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <time.h>
@@ -2413,7 +2517,7 @@ int main() {
 struct tm *tp; tp->tm_sec;
 ; return 0; }
 EOF
-if { (eval echo configure:2417: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2521: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm=time.h
 else
@@ -2434,8 +2538,84 @@ EOF
 fi
 
 
+echo $ac_n "checking for working const""... $ac_c" 1>&6
+echo "configure:2543: checking for working const" >&5
+if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2548 "configure"
+#include "confdefs.h"
+
+int main() {
+
+/* Ultrix mips cc rejects this.  */
+typedef int charset[2]; const charset x;
+/* SunOS 4.1.1 cc rejects this.  */
+char const *const *ccp;
+char **p;
+/* NEC SVR4.0.2 mips cc rejects this.  */
+struct point {int x, y;};
+static struct point const zero = {0,0};
+/* AIX XL C 1.02.0.0 rejects this.
+   It does not let you subtract one const X* pointer from another in an arm
+   of an if-expression whose if-part is not a constant expression */
+const char *g = "string";
+ccp = &g + (g ? g-g : 0);
+/* HPUX 7.0 cc rejects these. */
+++ccp;
+p = (char**) ccp;
+ccp = (char const *const *) p;
+{ /* SCO 3.2v4 cc rejects this.  */
+  char *t;
+  char const *s = 0 ? (char *) 0 : (char const *) 0;
+
+  *t++ = 0;
+}
+{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
+  int x[] = {25, 17};
+  const int *foo = &x[0];
+  ++foo;
+}
+{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
+  typedef const int *iptr;
+  iptr p = 0;
+  ++p;
+}
+{ /* AIX XL C 1.02.0.0 rejects this saying
+     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
+  struct s { int j; const int *ap[3]; };
+  struct s *b; b->j = 5;
+}
+{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
+  const int foo = 10;
+}
+
+; return 0; }
+EOF
+if { (eval echo configure:2597: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  ac_cv_c_const=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  ac_cv_c_const=no
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$ac_cv_c_const" 1>&6
+if test $ac_cv_c_const = no; then
+  cat >> confdefs.h <<\EOF
+#define const 
+EOF
+
+fi
+
+
 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
-echo "configure:2439: checking for 8-bit clean memcmp" >&5
+echo "configure:2619: checking for 8-bit clean memcmp" >&5
 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2443,7 +2623,7 @@ else
   ac_cv_func_memcmp_clean=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 2447 "configure"
+#line 2627 "configure"
 #include "confdefs.h"
 
 main()
@@ -2453,7 +2633,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:2457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_memcmp_clean=yes
 else
@@ -2471,12 +2651,12 @@ echo "$ac_t""$ac_cv_func_memcmp_clean" 1>&6
 test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.o"
 
 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:2475: checking return type of signal handlers" >&5
+echo "configure:2655: checking return type of signal handlers" >&5
 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2480 "configure"
+#line 2660 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <signal.h>
@@ -2493,7 +2673,7 @@ int main() {
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:2497: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2677: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_type_signal=void
 else
@@ -2512,12 +2692,12 @@ EOF
 
 
 echo $ac_n "checking for strftime""... $ac_c" 1>&6
-echo "configure:2516: checking for strftime" >&5
+echo "configure:2696: checking for strftime" >&5
 if eval "test \"`echo '$''{'ac_cv_func_strftime'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2521 "configure"
+#line 2701 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char strftime(); below.  */
@@ -2540,7 +2720,7 @@ strftime();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2724: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_strftime=yes"
 else
@@ -2562,7 +2742,7 @@ else
   echo "$ac_t""no" 1>&6
 # strftime is in -lintl on SCO UNIX.
 echo $ac_n "checking for strftime in -lintl""... $ac_c" 1>&6
-echo "configure:2566: checking for strftime in -lintl" >&5
+echo "configure:2746: checking for strftime in -lintl" >&5
 ac_lib_var=`echo intl'_'strftime | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2570,7 +2750,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lintl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2574 "configure"
+#line 2754 "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
@@ -2581,7 +2761,7 @@ int main() {
 strftime()
 ; return 0; }
 EOF
-if { (eval echo configure:2585: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2765: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2608,12 +2788,12 @@ fi
 fi
 
 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:2612: checking for vprintf" >&5
+echo "configure:2792: checking for vprintf" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2617 "configure"
+#line 2797 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vprintf(); below.  */
@@ -2636,7 +2816,7 @@ vprintf();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2640: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_vprintf=yes"
 else
@@ -2660,12 +2840,12 @@ fi
 
 if test "$ac_cv_func_vprintf" != yes; then
 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:2664: checking for _doprnt" >&5
+echo "configure:2844: checking for _doprnt" >&5
 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2669 "configure"
+#line 2849 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char _doprnt(); below.  */
@@ -2688,7 +2868,7 @@ _doprnt();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func__doprnt=yes"
 else
@@ -2713,7 +2893,7 @@ fi
 fi
 
 echo $ac_n "checking for wait3 that fills in rusage""... $ac_c" 1>&6
-echo "configure:2717: checking for wait3 that fills in rusage" >&5
+echo "configure:2897: checking for wait3 that fills in rusage" >&5
 if eval "test \"`echo '$''{'ac_cv_func_wait3_rusage'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2721,7 +2901,7 @@ else
   ac_cv_func_wait3_rusage=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 2725 "configure"
+#line 2905 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -2752,7 +2932,7 @@ main() {
   }
 }
 EOF
-if { (eval echo configure:2756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_wait3_rusage=yes
 else
@@ -2784,18 +2964,76 @@ for ac_func in \
        strdup                  \
        strerror                \
        strstr                  \
+       strrchr                 \
        strtod                  \
        strtol                  \
        strtoul                 \
+       memcpy                  \
+
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:2976: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2981 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
 
+; return 0; }
+EOF
+if { (eval echo configure:3004: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+
+for ac_func in strdup
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2794: checking for $ac_func" >&5
+echo "configure:3032: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2799 "configure"
+#line 3037 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2818,7 +3056,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2822: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2839,20 +3077,22 @@ EOF
  
 else
   echo "$ac_t""no" 1>&6
+LIBOBJS="$LIBOBJS ${ac_func}.o"
 fi
 done
 
 
+
 # Check Configuration
 
 echo $ac_n "checking declaration of sys_errlist""... $ac_c" 1>&6
-echo "configure:2850: checking declaration of sys_errlist" >&5
+echo "configure:3090: checking declaration of sys_errlist" >&5
 if eval "test \"`echo '$''{'cf_cv_dcl_sys_errlist'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
        cat > conftest.$ac_ext <<EOF
-#line 2856 "configure"
+#line 3096 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -2862,7 +3102,7 @@ int main() {
 char *c = (char *) *sys_errlist
 ; return 0; }
 EOF
-if { (eval echo configure:2866: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3106: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_dcl_sys_errlist=yes
 else
@@ -2883,20 +3123,20 @@ if test $cf_cv_dcl_sys_errlist = no ; then
 EOF
 
        echo $ac_n "checking existence of sys_errlist""... $ac_c" 1>&6
-echo "configure:2887: checking existence of sys_errlist" >&5
+echo "configure:3127: checking existence of sys_errlist" >&5
        if eval "test \"`echo '$''{'cf_cv_have_sys_errlist'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
                cat > conftest.$ac_ext <<EOF
-#line 2893 "configure"
+#line 3133 "configure"
 #include "confdefs.h"
 #include <errno.h>
 int main() {
 char *c = (char *) *sys_errlist
 ; return 0; }
 EOF
-if { (eval echo configure:2900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   cf_cv_have_sys_errlist=yes
 else
@@ -3030,6 +3270,9 @@ clients/finger/Makefile:etc/top.mk:clients/finger/Makefile.in:etc/rules.mk \
 clients/gopher/Makefile:etc/top.mk:clients/gopher/Makefile.in:etc/rules.mk \
 clients/mail500/Makefile:etc/top.mk:clients/mail500/Makefile.in:etc/rules.mk \
 clients/rcpt500/Makefile:etc/top.mk:clients/rcpt500/Makefile.in:etc/rules.mk \
+contrib/Makefile:etc/top.mk:contrib/Makefile.in:etc/dir.mk \
+contrib/saucer/Makefile:etc/top.mk:contrib/saucer/Makefile.in:etc/rules.mk \
+contrib/whois++/Makefile:etc/top.mk:contrib/whois++/Makefile.in:etc/rules.mk \
 libraries/Makefile:etc/top.mk:libraries/Makefile.in:etc/dir.mk         \
 libraries/libavl/Makefile:etc/top.mk:libraries/libavl/Makefile.in:etc/lib.mk \
 libraries/liblber/Makefile:etc/top.mk:libraries/liblber/Makefile.in:etc/lib.mk \
@@ -3046,6 +3289,7 @@ servers/slapd/back-shell/Makefile:etc/top.mk:servers/slapd/back-shell/Makefile.i
 servers/slapd/tools/Makefile:etc/top.mk:servers/slapd/tools/Makefile.in \
 servers/slapd/shell-backends/Makefile:etc/top.mk:servers/slapd/shell-backends/Makefile.in:etc/srv.mk \
 servers/slurpd/Makefile:etc/top.mk:servers/slurpd/Makefile.in:etc/srv.mk \
+tests/Makefile:etc/top.mk:tests/Makefile.in \
 Makefile:etc/top.mk:Makefile.in:etc/dir.mk include/portable.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
 EOF
 cat >> $CONFIG_STATUS <<EOF
@@ -3150,6 +3394,9 @@ clients/finger/Makefile:etc/top.mk:clients/finger/Makefile.in:etc/rules.mk \
 clients/gopher/Makefile:etc/top.mk:clients/gopher/Makefile.in:etc/rules.mk \
 clients/mail500/Makefile:etc/top.mk:clients/mail500/Makefile.in:etc/rules.mk \
 clients/rcpt500/Makefile:etc/top.mk:clients/rcpt500/Makefile.in:etc/rules.mk \
+contrib/Makefile:etc/top.mk:contrib/Makefile.in:etc/dir.mk \
+contrib/saucer/Makefile:etc/top.mk:contrib/saucer/Makefile.in:etc/rules.mk \
+contrib/whois++/Makefile:etc/top.mk:contrib/whois++/Makefile.in:etc/rules.mk \
 libraries/Makefile:etc/top.mk:libraries/Makefile.in:etc/dir.mk         \
 libraries/libavl/Makefile:etc/top.mk:libraries/libavl/Makefile.in:etc/lib.mk \
 libraries/liblber/Makefile:etc/top.mk:libraries/liblber/Makefile.in:etc/lib.mk \
@@ -3166,6 +3413,7 @@ servers/slapd/back-shell/Makefile:etc/top.mk:servers/slapd/back-shell/Makefile.i
 servers/slapd/tools/Makefile:etc/top.mk:servers/slapd/tools/Makefile.in \
 servers/slapd/shell-backends/Makefile:etc/top.mk:servers/slapd/shell-backends/Makefile.in:etc/srv.mk \
 servers/slurpd/Makefile:etc/top.mk:servers/slurpd/Makefile.in:etc/srv.mk \
+tests/Makefile:etc/top.mk:tests/Makefile.in \
 Makefile:etc/top.mk:Makefile.in:etc/dir.mk"}
 EOF
 cat >> $CONFIG_STATUS <<\EOF
index b0782dd0637ec683a3fb01202a231ca46ac69670..ff3cf94d08bd040a84c9689a1198b834246a3576 100644 (file)
@@ -238,15 +238,20 @@ AC_CHECK_HEADERS( \
 )
 
 dnl Checks for typedefs, structures, and compiler characteristics.
-AC_C_CONST
-AC_TYPE_UID_T
+AC_TYPE_GETGROUPS
+AC_TYPE_MODE_T
 AC_TYPE_OFF_T
 AC_TYPE_PID_T
+AC_TYPE_SIGNAL
 AC_TYPE_SIZE_T
+AC_TYPE_UID_T
 AC_STRUCT_ST_BLKSIZE
 AC_HEADER_TIME
 AC_STRUCT_TM
 
+dnl AC_C_BIGENDIAN
+AC_C_CONST
+
 dnl Checks for library functions.
 AC_FUNC_MEMCMP
 AC_TYPE_SIGNAL
@@ -263,11 +268,15 @@ AC_CHECK_FUNCS(           \
        strdup                  \
        strerror                \
        strstr                  \
+       strrchr                 \
        strtod                  \
        strtol                  \
        strtoul                 \
+       memcpy                  \
 )
 
+AC_REPLACE_FUNCS(strdup)
+
 # Check Configuration
 CF_SYS_ERRLIST
 
@@ -289,6 +298,9 @@ clients/finger/Makefile:etc/top.mk:clients/finger/Makefile.in:etc/rules.mk \
 clients/gopher/Makefile:etc/top.mk:clients/gopher/Makefile.in:etc/rules.mk \
 clients/mail500/Makefile:etc/top.mk:clients/mail500/Makefile.in:etc/rules.mk \
 clients/rcpt500/Makefile:etc/top.mk:clients/rcpt500/Makefile.in:etc/rules.mk \
+contrib/Makefile:etc/top.mk:contrib/Makefile.in:etc/dir.mk \
+contrib/saucer/Makefile:etc/top.mk:contrib/saucer/Makefile.in:etc/rules.mk \
+contrib/whois++/Makefile:etc/top.mk:contrib/whois++/Makefile.in:etc/rules.mk \
 libraries/Makefile:etc/top.mk:libraries/Makefile.in:etc/dir.mk         \
 libraries/libavl/Makefile:etc/top.mk:libraries/libavl/Makefile.in:etc/lib.mk \
 libraries/liblber/Makefile:etc/top.mk:libraries/liblber/Makefile.in:etc/lib.mk \
@@ -305,5 +317,6 @@ servers/slapd/back-shell/Makefile:etc/top.mk:servers/slapd/back-shell/Makefile.i
 servers/slapd/tools/Makefile:etc/top.mk:servers/slapd/tools/Makefile.in \
 servers/slapd/shell-backends/Makefile:etc/top.mk:servers/slapd/shell-backends/Makefile.in:etc/srv.mk \
 servers/slurpd/Makefile:etc/top.mk:servers/slurpd/Makefile.in:etc/srv.mk \
+tests/Makefile:etc/top.mk:tests/Makefile.in \
 Makefile:etc/top.mk:Makefile.in:etc/dir.mk, \
        [date > stamp-h])
diff --git a/contrib/saucer/Make-template b/contrib/saucer/Make-template
deleted file mode 100644 (file)
index cdd9233..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-# Makefile for LDAP "saucer" client
-
-HDIR   = $(LDAPSRC)/include
-INSTMAN        = $(MANDIR)/man$(SECT)
-LDAPSRC        = ../..
-LDIR   = $(LDAPSRC)/libraries
-SECT   = 1
-VERFILE        = $(LDAPSRC)/build/version
-
-CFLAGS = -I$(HDIR) $(DEFINES) $(ACFLAGS)
-SRCS   = main.c
-OBJS   = $(SRCS:.c=.o)
-LIBS   = -lldap -llber $(KRBLIBFLAG) $(KRBLIBS) $(ALIBS)
-
-all:   saucer
-
-saucer:        $(OBJS)
-       $(CC) $(ALDFLAGS) -o $@ $(OBJS) -L$(LDIR) $(LIBS)
-
-protoize: $(SRCS)
-       protoize -c "$(CFLAGS)" $(SRCS)
-
-unprotoize: $(SRCS)
-       unprotoize -c "$(CFLAGS)" $(SRCS)
-
-install:       saucer FORCE
-       -$(MKDIR) -p $(BINDIR)
-       $(INSTALL) $(INSTALLFLAGS) -m 755 saucer $(BINDIR)
-       -$(MKDIR) -p $(INSTMAN)
-       @TMPMAN=/tmp/ldapman.$$$$; \
-       VERSION=`$(CAT) $(VERFILE)`; \
-       for page in *.$(SECT); do \
-           $(SED) -e 's%ETCDIR%$(ETCDIR)%' -e "s%LDVERSION%$$VERSION%" \
-                   $$page > $$TMPMAN; \
-           echo "installing $(INSTMAN)/$$page"; \
-           $(INSTALL) $(INSTALLFLAGS) -m 644 $$TMPMAN $(INSTMAN)/$$page; \
-       done; \
-       $(RM) $$TMPMAN
-
-lint:   FORCE
-       $(LINT) $(INCLUDES) $(DEFINES) $(SRCS)
-
-5lint:  FORCE
-       $(5LINT) $(INCLUDES) $(DEFINES) $(SRCS)
-
-clean:  FORCE
-       $(RM) *.o core a.out saucer
-
-depend: FORCE
-       $(MKDEP) $(INCLUDES) $(DEFINES) $(SRCS)
-
-links:
-       @$(LN) .src/*.[ch] .
-
diff --git a/contrib/whois++/Makefile b/contrib/whois++/Makefile
deleted file mode 100644 (file)
index a2f9b2e..0000000
+++ /dev/null
@@ -1,81 +0,0 @@
-#
-# Configuration parameters, can be overridden in config file
-#
-LDAPSRC                = ../..
-CONFIG_DIRECTORY       =       $(ETCDIR)/whois++
-HELP_DIRECTORY =       /usr/local/isode/help/whois++
-LDAPHOST       = "localhost"
-#
-# Where to stuff the man page
-MANDIR         = /usr/local/isode/man
-MANSEC         = 8
-#
-# Syslog facility to log queries under, using info serverity level
-#
-FACILITY       = LOG_LOCAL3
-#
-# Additional system libraries
-# Under Ultrix I use the 4.3 syslog, hence the additional syslog library
-#
-#SYSLIBS       = -li -lsyslog
-#
-# If you want RFC931 logging you must have log_tcp source available
-#
-SRCS   = whois++.c command.c config.c describe.c help.c output.c template.c \
-         util.c version.c # /local/src/log_tcp/rfc931.c
-HDRS   = whois++.h
-OBJS   = ${SRCS:.c=.o}
-HOST   = `hostname`
-# This returns a date such as "26 April 1993", unfortunately SunOS doesn't
-# understand the %B abd %Y macros so you may need to change this.
-#DATE  = `date +'%d %B %Y'`
-DATE   = `date +'%D'`  # this gives 4/26/93 format
-REVISION       = 2
-
-DEFINES = -DETCDIR=\"$(ETCDIR)\" -DBUILD="\"$(USER)@$(HOST) on $(DATE)\"" \
-         -DCONFIG_DIRECTORY=\"$(CONFIG_DIRECTORY)\" -DMAIN \
-         -DHELP_DIRECTORY=\"$(HELP_DIRECTORY)\" -DREVISION="$(REVISION)" \
-         -DPROTOCOL="\"[FIRST DRAFT - 15 April 1993]\"" -DRELEASE=\"BETA\" \
-         -DFACILITY=$(FACILITY) -DDEFAULT_LDAPHOST=\"$(LDAPHOST)\" # -DRFC931
-
-CFLAGS = -I$(LDAPSRC)/include -I/usr/local/include $(ACFLAGS)
-LIBS   = -L$(LDAPSRC)/libraries/libldap -lldap -L$(LDAPSRC)/libraries/liblber \
-        -llber $(SYSLIBS) $(KRBLIBFLAG) $(KRBLIBS)
-
-all:   whois++d
-
-whois++d:      $(OBJS) $(LDAPSRC)/libraries/libldap/libldap.a
-       $(CC) $(ALDFLAGS) -o $@ $(OBJS) $(LIBS)
-
-whois++.o:     whois++.c $(HDRS)
-       $(CC) $(CFLAGS) $(DEFINES) -c whois++.c
-
-install:       inst-whois++
-
-inst-whois++:  $(ETCDIR)/whois++d
-       -mkdir -p $(CONFIG_DIRECTORY)
-       cp -r templates $(CONFIG_DIRECTORY)
-       -mkdir -p $(HELP_DIRECTORY)
-       cp -r helpfiles/* $(HELP_DIRECTORY)
-       sed -e 's#ETCDIR#$(ETCDIR)#' whois++d.man > $(MANDIR)/man$(MANSEC)/whois++d.$(MANSEC)
-       @echo "Don't forget to modify and install the tailor file"
-
-$(ETCDIR)/whois++d:    whois++d
-       install -c -m 755 whois++d $(ETCDIR)
-
-lint:;
-       lint $(SRCS)
-
-5lint:;
-       /usr/5bin/lint $(SRCS)
-
-clean:;
-       rm -f *.o core a.out whois++d
-
-depend:;
-       ../mkdep $(CFLAGS) $(SRCS)
-
-# DO NOT DELETE THIS LINE -- mkdep uses it.
-# DO NOT PUT ANYTHING AFTER THIS LINE, IT WILL GO AWAY.
-
-# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
index d6ad620cc1d24f37ce5c23d918f79ac4f166c68c..c7c4a29a42d8d9bbc74b72adf1d8762e1ed2f5cc 100644 (file)
  * is provided ``as is'' without express or implied warranty.
  */
 
-#ifndef _BRIDGE_H
-#define _BRIDGE_H
+/* This file SHOULD go away !!! */
+
+#ifndef _LDAP_BRIDGE_H
+#define _LDAP_BRIDGE_H
 
 /*
  * portable.h for LDAP -- this is where we define common stuff to make
 extern char *strdup();
 #endif /* ultrix || nextstep */
 
-#endif /* _BRIDGE_H */
+#endif /* _LDAP_BRIDGE_H */
index 0e500aae611d3ba132deb3a8d04811032cf769a2..5cc74cfe9c0e83e2590a224b8b936beb45daae35 100644 (file)
        /* default place to start searching */
 #define DEFAULT_BASE   "o=Your Organization Name, c=US"
 
+#define EDITOR         "@EDITOR@"
+
+#define DEFAULT_SCONFDIR       "@SCONFDIR@/ldap"
+#define        DEFAULT_SBINDIR         "@SBINDIR@"
+#define        DEFAULT_LIBEXECDIR      "@LIBEXECDIR@"
+
 /*********************************************************************
  *                                                                   *
  * You probably do not need to edit anything below this point        *
index 5d96247e35a4b40fa9bd0e5f42345fbfa1b5293f..d60d10b32f86f156fbad796723db8d5c8c3a52f3 100644 (file)
@@ -1,4 +1,2 @@
 
-
-#include "bridge.h"
 #endif /* _LDAP_PORTABLE_H */
index 53f94ec756f35f5ca19f06b63bfc1d586e8f5f05..03c7c7508de7a5fcc32258a3ebe27c875ced1176 100644 (file)
 /* Define to empty if the keyword does not work.  */
 #undef const
 
+/* Define to the type of elements in the array set by `getgroups'.
+   Usually this is either `int' or `gid_t'.  */
+#undef GETGROUPS_T
+
 /* Define to `int' if <sys/types.h> doesn't define.  */
 #undef gid_t
 
@@ -39,6 +43,9 @@
 /* Define if you have the wait3 system call.  */
 #undef HAVE_WAIT3
 
+/* Define to `int' if <sys/types.h> doesn't define.  */
+#undef mode_t
+
 /* Define to `long' if <sys/types.h> doesn't define.  */
 #undef off_t
 
 /* Define if you have the gettimeofday function.  */
 #undef HAVE_GETTIMEOFDAY
 
+/* Define if you have the memcpy function.  */
+#undef HAVE_MEMCPY
+
 /* Define if you have the mktime function.  */
 #undef HAVE_MKTIME
 
 /* Define if you have the strerror function.  */
 #undef HAVE_STRERROR
 
+/* Define if you have the strrchr function.  */
+#undef HAVE_STRRCHR
+
 /* Define if you have the strstr function.  */
 #undef HAVE_STRSTR
 
 /* Define if you have the compat library (-lcompat).  */
 #undef HAVE_LIBCOMPAT
 
-
-#include "bridge.h"
 #endif /* _LDAP_PORTABLE_H */
index a722c9eb7a319a12ad027c85310c1d9c6264ccb4..b482e3351edbc1ac9d177a832a693ea6e559e6d9 100644 (file)
 #if defined(NeXT) || defined(VMS)
 #include <stdlib.h>
 #else /* next || vms */
+#ifndef __FreeBSD__
 #include <malloc.h>
+#endif
 #endif /* next || vms */
-#if defined(BC31) || defined(_WIN32)
+#if defined(BC31) || defined(_WIN32) || defined(sunos5)
 #include <stdarg.h>
-#else /* BC31 || _WIN32 */
+#else /* BC31 || _WIN32 || defined(sunos5) */
 #include <varargs.h>
-#endif /* BC31 || _WIN32 */
+#endif /* BC31 || _WIN32 || defined(sunos5) */
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <netinet/in.h>
@@ -155,6 +157,7 @@ ber_getnint( BerElement *ber, long *num, int len )
 {
        int     diff, sign, i;
        long    netnum;
+       char    *p;
 
        /*
         * The tag and length have already been stripped off.  We should
@@ -172,11 +175,12 @@ ber_getnint( BerElement *ber, long *num, int len )
        if ( ber_read( ber, ((char *) &netnum) + diff, len ) != len )
                return( -1 );
 
-       /* sign extend if necessary */
-       sign = ((0x80 << ((len - 1) * 8)) & netnum);
-       if ( sign && len < sizeof(long) ) {
-               for ( i = sizeof(long) - 1; i > len - 1; i-- ) {
-                       netnum |= (0xffL << (i * 8));
+        /* sign extend if necessary */
+        p = (char *) &netnum;
+        sign = (0x80 & *(p+diff) );
+        if ( sign && len < sizeof(long) ) {
+                for ( i = 0; i < diff; i++ ) {
+                        *(p+i) = 0xff;
                }
        }
        *num = LBER_NTOHL( netnum );
@@ -383,7 +387,7 @@ ber_next_element( BerElement *ber, unsigned long *len, char *last )
 /* VARARGS */
 unsigned long
 ber_scanf(
-#if defined( MACOS ) || defined( BC31 ) || defined( _WIN32 )
+#if defined( MACOS ) || defined( BC31 ) || defined( _WIN32 ) || defined(sunos5)
        BerElement *ber, char *fmt, ... )
 #else
        va_alist )
@@ -391,7 +395,7 @@ va_dcl
 #endif
 {
        va_list         ap;
-#if !defined( MACOS ) && !defined( BC31 ) && !defined( _WIN32 )
+#if !defined( MACOS ) && !defined( BC31 ) && !defined( _WIN32 ) && !defined(sunos5)
        BerElement      *ber;
        char            *fmt;
 #endif
@@ -402,7 +406,7 @@ va_dcl
        long            *l, rc, tag;
        unsigned long   len;
 
-#if defined( MACOS ) || defined( BC31 ) || defined( _WIN32 )
+#if defined( MACOS ) || defined( BC31 ) || defined( _WIN32 ) || defined(sunos5)
        va_start( ap, fmt );
 #else
        va_start( ap );
index cd95f8932b2633341fd0049c72f9f1a223b36378..0090cab852301fa6e5000906432b3e96cc05e6c7 100644 (file)
 #if defined(NeXT) || defined(VMS)
 #include <stdlib.h>
 #else /* next || vms */
+#ifndef __FreeBSD__
 #include <malloc.h>
+#endif
 #endif /* next || vms */
-#if defined( BC31 ) || defined( _WIN32 )
+#if defined( BC31 ) || defined( _WIN32 ) || defined( sunos5 )
 #include <stdarg.h>
 #else /* BC31 || _WIN32 */
 #include <varargs.h>
@@ -520,7 +522,7 @@ ber_put_set( BerElement *ber )
 /* VARARGS */
 int
 ber_printf(
-#if defined( MACOS ) || defined( _WIN32 ) || defined( BC31 )
+#if defined( MACOS ) || defined( _WIN32 ) || defined( BC31 ) || defined( sunos5 )
        BerElement *ber, char *fmt, ... )
 #else /* MACOS || _WIN32 || BC31 */
        va_alist )
@@ -528,22 +530,22 @@ va_dcl
 #endif /* MACOS || _WIN32 || BC31 */
 {
        va_list         ap;
-#if !defined( MACOS ) && !defined( _WIN32 ) && !defined( BC31 )
+#if !defined( MACOS ) && !defined( _WIN32 ) && !defined( BC31 ) && !defined( sunos5 )
        BerElement      *ber;
        char            *fmt;
-#endif /* !MACOS && !_WIN32 && !BC31 */
+#endif /* !MACOS && !_WIN32 && !BC31 && !sunos5 */
        char            *s, **ss;
        struct berval   **bv;
        int             rc, i;
        unsigned long   len;
 
-#if defined( MACOS ) || defined( _WIN32 ) || defined( BC31 )
+#if defined( MACOS ) || defined( _WIN32 ) || defined( BC31 ) || defined( sunos5 )
        va_start( ap, fmt );
-#else /* MACOS || _WIN32 || BC31 */
+#else /* MACOS || _WIN32 || BC31 || defined( sunos5 ) */
        va_start( ap );
        ber = va_arg( ap, BerElement * );
        fmt = va_arg( ap, char * );
-#endif /* MACOS || _WIN32 || BC31 */
+#endif /* MACOS || _WIN32 || BC31 || defined( sunos5 ) */
 
        for ( rc = 0; *fmt && rc != -1; fmt++ ) {
                switch ( *fmt ) {
index 7ebfa520115505ee01aca4a38832d5d35d94c818..d4dfc3af608651cf3534e02742c24e3bfc9f3a72 100644 (file)
@@ -60,11 +60,8 @@ chlog2replog: chlog2replog.o ../lock.o ../ch_malloc.o
 ldif2index:    ldif2index.o ../libbackends.a $(OBJS2)
        $(CC) $(LDFLAGS) -o $@ ldif2index.o $(OBJS2) ../libbackends.a $(LIBS)
 
-ldif2ldbm:     ldif2ldbm.sed.o ../libbackends.a $(OBJS2)
-       $(CC) $(LDFLAGS) -o $@ ldif2ldbm.sed.o $(OBJS2) ../libbackends.a $(LIBS)
-
-ldif2ldbm.sed.c: ldif2ldbm.c
-       $(SED) -e 's;%ETCDIR%;$(sysconfdir)/ldap;' ldif2ldbm.c > ldif2ldbm.sed.c
+ldif2ldbm:     ldif2ldbm.o ../libbackends.a $(OBJS2)
+       $(CC) $(LDFLAGS) -o $@ ldif2ldbm.o $(OBJS2) ../libbackends.a $(LIBS)
 
 ldif2id2entry: ldif2id2entry.o ../libbackends.a $(OBJS2)
        $(CC) $(LDFLAGS) -o $@ ldif2id2entry.o $(OBJS2) ../libbackends.a $(LIBS)
index e6a28999ccb0a3023b5f9c30677d675a0f343187..4f0546d171bfa908a184862d68df1b524ded5952 100644 (file)
@@ -1,10 +1,12 @@
 /* centipede.c - generate and install indexing information (view w/tabstop=4) */
 
-#include <stdio.h>
 #include "portable.h"
-#include <string.h>
+
+#include <stdio.h>
+#include "ldap_string.h"
 #include <ctype.h>
-#include <sys/time.h>
+#include "ldap_time.h"
+
 #include <lber.h>
 #include <ldap.h>
 #include <ldapconfig.h>
index f9f3b3c5d78b2cd8c2814d57e8182ec4c8408601..0b053af50623560738a68fe25d9df72dab1f4586 100644 (file)
  * slapd/slurpd locking conventions.
  */
 
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <stdlib.h>
 #include <ctype.h>
 
index d46be1edfd60d694c23ba5a2454fbb80b963fbd8..4ffd7168be5d204b3c01bd094cc69b7b6b933e77 100644 (file)
  * is provided ``as is'' without express or implied warranty.
  */
 
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
-#include <dirent.h>
+
+#include "ldap_string.h"
+#include "ldap_dirent.h"
+
 #include <stdlib.h>
 #include <ctype.h>
 #include <sys/types.h>
index 4fa12c407aefacef435a029e7c03f2c866238efe..bb66c7facd479b9d9dd4a1579a372bf453ccf24a 100644 (file)
  * is provided ``as is'' without express or implied warranty.
  */
 
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <ctype.h>
+
 #include <quipu/commonarg.h>
 #include <quipu/attrvalue.h>
 #include <quipu/ds_error.h>
 #include <quipu/ds_search.h>
 /* #include <quipu/dap2.h> */
 #include <quipu/dua.h>
+
 #include <sys/types.h>
 
 #include "lber.h"
index e947b807d7dc30f707dc863d2e81918e3f5edead..e9d70ba5bd0711019987877bc122392d4f6d58ac 100644 (file)
@@ -1,9 +1,10 @@
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <ctype.h>
 #include <sys/types.h>
 #include <sys/socket.h>
-#include "portable.h"
 #include "ldbm.h"
 #include "../slap.h"
 
index 56513ab5b84a11a7922ac31b82601349b0e88456..5dd55f392f3b1269b98dd127eda0759d3c83f06e 100644 (file)
@@ -1,22 +1,24 @@
+#include "portable.h"
+
 #include <stdio.h>
 #include <string.h>
 #include <stdlib.h>
 #include <fcntl.h>
 #include <sys/types.h>
 #include <sys/socket.h>
-#include <sys/time.h>
+#include "ldap_time.h"
 #include <sys/resource.h>
-#include <sys/wait.h>
+#include "ldap_wait.h"
 #include <sys/param.h>
 #include <sys/stat.h>
 #include <limits.h>
-#include "portable.h"
+
+#include "bridge.h"
+
 #include "ldapconfig.h"
 #include "../slap.h"
 #include "../back-ldbm/back-ldbm.h"
 
-#define EDITOR "/usr/ucb/vi"
-
 extern IDList          *idl_fetch();
 extern Backend         *select_backend();
 extern struct dbcache  *ldbm_cache_open();
index 283d49457108593b64ae927f2c6fec90ba109aa5..456433bdf489538b5dc26dc0a4eb13348570794c 100644 (file)
@@ -1,5 +1,7 @@
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <memory.h>
 #include <sys/types.h>
 #include <sys/socket.h>
index 2fb2aaf6039066f35d242610872be9686747f398..f8a1aef52bd920e6273766e311b095d461f0af9b 100644 (file)
@@ -1,11 +1,14 @@
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include "../slap.h"
 #include "../back-ldbm/back-ldbm.h"
 
-#define DEFAULT_CONFIGFILE     "/usr/local/etc/slapd.conf"
+#include "ldapconfig.h"
+
 #define MAXARGS                100
 
 extern struct dbcache  *ldbm_cache_open();
@@ -69,7 +72,7 @@ main( int argc, char **argv )
        Avlnode         *avltypes = NULL;
        extern char     *optarg;
 
-       tailorfile = DEFAULT_CONFIGFILE;
+       tailorfile = SLAPD_DEFAULT_CONFIGFILE;
        dbnum = -1;
        while ( (i = getopt( argc, argv, "d:f:i:n:" )) != EOF ) {
                switch ( i ) {
@@ -121,7 +124,7 @@ main( int argc, char **argv )
                        fprintf( stderr, "No ldbm database found in config file\n" );
                        exit( 1 );
                }
-       } else if ( dbnum < 1 || dbnum > nbackends ) {
+       } else if ( dbnum < 0 || dbnum > (nbackends-1) ) {
                fprintf( stderr, "Database number selected via -n is out of range\n" );
                fprintf( stderr, "Must be in the range 1 to %d (number of databases in the config file)\n", nbackends );
                exit( 1 );
index 5c8874c513206ed06f65ddd22d54107b59f8a18c..3010d1d58ccc7d847801a474f968005bced3edab 100644 (file)
@@ -1,11 +1,13 @@
+#include "portable.h"
+
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include "../slap.h"
 #include "../back-ldbm/back-ldbm.h"
+#include "ldapconfig.h"
 
-#define DEFAULT_CONFIGFILE     "/usr/local/etc/slapd.conf"
 #define MAXARGS                100
 
 extern struct dbcache  *ldbm_cache_open();
@@ -65,7 +67,7 @@ main( int argc, char **argv )
        FILE            *fp;
        extern char     *optarg;
 
-       tailorfile = DEFAULT_CONFIGFILE;
+       tailorfile = SLAPD_DEFAULT_CONFIGFILE;
        dbnum = -1;
        while ( (i = getopt( argc, argv, "d:f:i:n:" )) != EOF ) {
                switch ( i ) {
@@ -117,7 +119,7 @@ main( int argc, char **argv )
                        fprintf( stderr, "No ldbm database found in config file\n" );
                        exit( 1 );
                }
-       } else if ( dbnum < 1 || dbnum > nbackends ) {
+       } else if ( dbnum < 0 || dbnum > (nbackends-1) ) {
                fprintf( stderr, "Database number selected via -n is out of range\n" );
                fprintf( stderr, "Must be in the range 1 to %d (number of databases in the config file)\n", nbackends );
                exit( 1 );
index 8f80d3c6b296e52094ab4a119493d370db624787..71318e0292d3cf7bab514fd1b233e0803faaedc9 100644 (file)
@@ -1,12 +1,13 @@
 #include "portable.h"
 
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include "../slap.h"
 
-#define DEFAULT_CONFIGFILE      "/usr/local/etc/slapd.conf"
+#include "ldapconfig.h"
+
 #define MAXARGS                100
 
 extern void    attr_index_config();
@@ -61,7 +62,7 @@ main( int argc, char **argv )
        extern char     *optarg;
 
        inputfile = NULL;
-       tailorfile = DEFAULT_CONFIGFILE;
+       tailorfile = SLAPD_DEFAULT_CONFIGFILE;
        dbnum = -1;
        while ( (i = getopt( argc, argv, "d:f:i:n:" )) != EOF ) {
                switch ( i ) {
index b2caa7b3cc0d87f86bd6cfd8b42ce1df40c3654f..56531b4fbc2f95b20b4416741bde5e40e8f7b865 100644 (file)
@@ -1,17 +1,17 @@
+#include "portable.h"
 #include <stdio.h>
-#include <string.h>
+#include "ldap_string.h"
 #include <sys/types.h>
 #include <sys/socket.h>
 #include <sys/param.h>
 #include "../slap.h"
 #include "../back-ldbm/back-ldbm.h"
+#include "ldapconfig.h"
 
-#define DEFAULT_CONFIGFILE     "%ETCDIR%/slapd.conf"
-#define DEFAULT_ETCDIR         "%ETCDIR%"
 #define INDEXCMD               "ldif2index"
 #define ID2ENTRYCMD            "ldif2id2entry"
-#define ID2CHILDRENCMD         "ldif2id2children"
-#define MAXARGS                100
+#define ID2CHILDRENCMD "ldif2id2children"
+#define MAXARGS        100
 
 extern void            attr_index_config();
 extern char            *str_getline();
@@ -74,8 +74,8 @@ main( int argc, char **argv )
        Avlnode         *avltypes = NULL;
        extern char     *optarg;
 
-       etcdir = DEFAULT_ETCDIR;
-       tailorfile = DEFAULT_CONFIGFILE;
+       etcdir = DEFAULT_SBINDIR;
+       tailorfile = SLAPD_DEFAULT_CONFIGFILE;
        dbnum = -1;
        while ( (i = getopt( argc, argv, "d:e:f:i:j:n:" )) != EOF ) {
                switch ( i ) {
@@ -135,7 +135,7 @@ main( int argc, char **argv )
                        fprintf( stderr, "No ldbm database found in config file\n" );
                        exit( 1 );
                }
-       } else if ( dbnum < 0 || dbnum > nbackends ) {
+       } else if ( dbnum < 0 || dbnum > (nbackends-1) ) {
                fprintf( stderr, "Database number selected via -n is out of range\n" );
                fprintf( stderr, "Must be in the range 1 to %d (number of databases in the config file)\n", nbackends );
                exit( 1 );
@@ -157,7 +157,7 @@ main( int argc, char **argv )
        args[i++] = "-f";
        args[i++] = tailorfile;
        args[i++] = "-n";
-       sprintf( buf2, "%d", dbnum );
+       sprintf( buf2, "%d", dbnum+1 );
        args[i++] = buf2;
        if ( ldap_debug ) {
                sprintf( buf3, "%d", ldap_debug );
@@ -179,7 +179,7 @@ main( int argc, char **argv )
        args[i++] = "-f";
        args[i++] = tailorfile;
        args[i++] = "-n";
-       sprintf( buf2, "%d", dbnum );
+       sprintf( buf2, "%d", dbnum+1 );
        args[i++] = buf2;
        if ( ldap_debug ) {
                sprintf( buf3, "%d", ldap_debug );
@@ -201,7 +201,7 @@ main( int argc, char **argv )
        args[i++] = "-f";
        args[i++] = tailorfile;
        args[i++] = "-n";
-       sprintf( buf2, "%d", dbnum );
+       sprintf( buf2, "%d", dbnum+1 );
        args[i++] = buf2;
        if ( ldap_debug ) {
                sprintf( buf3, "%d", ldap_debug );
index 45d82301007b6866f9aedf8e2379b24f53f852b9..d2daa7a2ee6cd0079c1db44ffa4f30786c71d33f 100644 (file)
@@ -1,8 +1,9 @@
+#include "portable.h"
+
 #include <stdio.h>
 #include <ldbm.h>
 #include <lber.h>
 #include <ldap.h>
-#include "portable.h"
 
 #define CACHE_SIZE     1000000
 #define MODE           0600
diff --git a/tests/Make-template b/tests/Make-template
deleted file mode 100644 (file)
index f8cae98..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-#-----------------------------------------------------------------------------
-# Copyright (c) 1996 Regents of the University of Michigan.
-# All rights reserved.
-#
-# Redistribution and use in source and binary forms are permitted
-# provided that this notice is preserved and that due credit is given
-# to the University of Michigan at Ann Arbor. The name of the University
-# may not be used to endorse or promote products derived from this
-# software without specific prior written permission. This software
-# is provided ``as is'' without express or implied warranty.
-#
-#       LDAP tests Make template file
-#
-#-----------------------------------------------------------------------------
-
-SCRIPTSDIR=./scripts
-
-all:   FORCE
-       @echo "Initiating LDAP tests..."; \
-       $(SCRIPTSDIR)/all $(SCRIPTSDIR)
-
-install:       FORCE
-
-depend:        FORCE
-
-clean: FORCE
-       $(RM) test-db/* test-repl/*
-
-veryclean:     clean
-
-links:
-       @echo "making links in `$(PWD)`"; \
-       $(LN) .src/scripts . ; \
-       $(LN) .src/data . ; \
-       $(MKDIR) test-db test-repl