mirror of
https://git.openldap.org/openldap/openldap.git
synced 2026-06-09 08:42:22 -04:00
more autoconf changes
This commit is contained in:
parent
09189d4dc6
commit
114f2cc950
28 changed files with 698 additions and 523 deletions
21
Makefile.in
21
Makefile.in
|
|
@ -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
|
||||
|
||||
|
|
|
|||
8
aclocal.m4
vendored
8
aclocal.m4
vendored
|
|
@ -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.
|
||||
|
|
|
|||
|
|
@ -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 */
|
||||
|
|
|
|||
|
|
@ -10,9 +10,11 @@
|
|||
* 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
|
||||
|
|
@ -25,10 +27,10 @@
|
|||
#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
|
||||
|
|
|
|||
17
configure.in
17
configure.in
|
|
@ -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])
|
||||
|
|
|
|||
|
|
@ -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] .
|
||||
|
||||
|
|
@ -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
|
||||
|
|
@ -10,8 +10,10 @@
|
|||
* 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
|
||||
|
|
@ -212,4 +214,4 @@
|
|||
extern char *strdup();
|
||||
#endif /* ultrix || nextstep */
|
||||
|
||||
#endif /* _BRIDGE_H */
|
||||
#endif /* _LDAP_BRIDGE_H */
|
||||
|
|
|
|||
|
|
@ -27,6 +27,12 @@
|
|||
/* 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 *
|
||||
|
|
|
|||
|
|
@ -1,4 +1,2 @@
|
|||
|
||||
|
||||
#include "bridge.h"
|
||||
#endif /* _LDAP_PORTABLE_H */
|
||||
|
|
|
|||
|
|
@ -18,6 +18,10 @@
|
|||
/* 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
|
||||
|
||||
|
|
@ -108,6 +115,9 @@
|
|||
/* 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
|
||||
|
||||
|
|
@ -123,6 +133,9 @@
|
|||
/* 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
|
||||
|
||||
|
|
@ -180,6 +193,4 @@
|
|||
/* Define if you have the compat library (-lcompat). */
|
||||
#undef HAVE_LIBCOMPAT
|
||||
|
||||
|
||||
#include "bridge.h"
|
||||
#endif /* _LDAP_PORTABLE_H */
|
||||
|
|
|
|||
|
|
@ -20,13 +20,15 @@
|
|||
#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 );
|
||||
|
|
|
|||
|
|
@ -20,9 +20,11 @@
|
|||
#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 ) {
|
||||
|
|
|
|||
|
|
@ -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)
|
||||
|
|
|
|||
|
|
@ -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>
|
||||
|
|
|
|||
|
|
@ -16,8 +16,10 @@
|
|||
* slapd/slurpd locking conventions.
|
||||
*/
|
||||
|
||||
#include "portable.h"
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include "ldap_string.h"
|
||||
#include <stdlib.h>
|
||||
#include <ctype.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -10,9 +10,13 @@
|
|||
* 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>
|
||||
|
|
|
|||
|
|
@ -10,15 +10,19 @@
|
|||
* 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"
|
||||
|
|
|
|||
|
|
@ -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"
|
||||
|
||||
|
|
|
|||
|
|
@ -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();
|
||||
|
|
|
|||
|
|
@ -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>
|
||||
|
|
|
|||
|
|
@ -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 );
|
||||
|
|
|
|||
|
|
@ -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 );
|
||||
|
|
|
|||
|
|
@ -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 ) {
|
||||
|
|
|
|||
|
|
@ -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 );
|
||||
|
|
|
|||
|
|
@ -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
|
||||
|
|
|
|||
|
|
@ -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
|
||||
Loading…
Reference in a new issue