From: Kurt Zeilenga Date: Thu, 17 Sep 1998 10:13:13 +0000 (+0000) Subject: Libraries actually compiles using current templates... X-Git-Tag: PHP3_TOOL_0_0~18^2~122 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=adf3d5a200cbbb84d25bae2fa200f6d10420f430;p=openldap Libraries actually compiles using current templates... however much is still needed (included db2 and thread detection) --- diff --git a/acconfig.h b/acconfig.h index e204299f8a..24eadb2950 100644 --- a/acconfig.h +++ b/acconfig.h @@ -17,32 +17,32 @@ /* define this to remove -lldap cache support */ #undef LDAP_NOCACHE -/* define this for phonetic support */ -#undef LDAP_PHONETIC - /* define this for LDAP referrals support */ #undef LDAP_REFERRALS +/* define this for phonetic support */ +#undef SLAPD_PHONETIC + /* define this to use SLAPD shell backend */ -#undef SLAPD_SHELL +/* #undef SLAPD_SHELL */ /* define this to use SLAPD passwd backend */ -#undef SLAPD_PASSWD +/* #undef SLAPD_PASSWD */ /* define this to use SLAPD LDBM backend */ -#undef SLAPD_LDBM +/* #undef SLAPD_LDBM */ /* define this to use DBBTREE w/ LDBM backend */ -#undef LDBM_USE_DBBTREE +/* #undef LDBM_USE_DBBTREE */ /* define this to use DBHASH w/ LDBM backend */ -#undef LDBM_USE_DBHASH +/* #undef LDBM_USE_DBHASH */ /* define this to use GDBM w/ LDBM backend */ -#undef LDBM_USE_GDBM +/* #undef LDBM_USE_GDBM */ /* define this to use NDBM w/ LDBM backend */ -#undef LDBM_USE_NDBM +/* #undef LDBM_USE_NDBM */ /* Leave that blank line there!! Autoheader needs it. */ diff --git a/build/top.mk b/build/top.mk index 690cc2f579..30b1c515ad 100644 --- a/build/top.mk +++ b/build/top.mk @@ -78,7 +78,7 @@ LIBDB = @LIBDB@ # Our Defaults CC = $(AC_CC) -DEFS = $(AC_DEFS) $(INCLUDEDIR) $(LDAP_DEFS) +DEFS = $(AC_DEFS) $(INCLUDEDIR) $(LDAP_DEFS) $(XDEFS) LIBS = -L$(LDAP_LIBDIR) $(LDAP_LIBS) $(XLIBS) $(AC_LIBS) CFLAGS = $(AC_CFLAGS) $(DEFS) $(DEFINES) diff --git a/configure.in b/configure.in index 4ce3673408..1d0f858b82 100644 --- a/configure.in +++ b/configure.in @@ -190,9 +190,10 @@ AC_PATH_PROG(FINGER, finger, /usr/ucb/finger, $PATH:/usr/ucb) ldbm_use="none" -LIBDB="" +LDBM_LIB="" +LDBM_DEFS="" -if test "$BUILD_LDBM" = "yes" ; then +if test "$SLAPD_LDBM" = "yes" ; then if test $ldbm_prefer = any -o $ldbm_prefer = dbbtree \ -o $ldbm_prefer = dbhash ; then AC_CHECK_FUNC(dbopen,[ @@ -201,36 +202,37 @@ if test "$BUILD_LDBM" = "yes" ; then AC_CHECK_LIB(db,dbopen,[ ldbm_use=$ldbm_prefer ldbm_prefer=found - LIBDB="-ldb" + LDBM_LIB="-ldb" ]) ]) if test $ldbm_prefer = found ; then if test $ldbm_use = dbhash ; then - AC_DEFINE(LDBM_USE_DBHASH,1) -dnl LDAP_DEFS="$LDAP_DEFS -DLDBM_USE_DBHASH" +dnl AC_DEFINE(LDBM_USE_DBHASH,1) + LDBM_DEFS="$LDAP_DEFS -DLDBM_USE_DBHASH" else - AC_DEFINE(LDBM_USE_DBBTREE,1) -dnl LDAP_DEFS="$LDAP_DEFS -DLDBM_USE_DBBTREE" +dnl AC_DEFINE(LDBM_USE_DBBTREE,1) + LDBM_DEFS="$LDAP_DEFS -DLDBM_USE_DBBTREE" fi fi fi + if test $ldbm_prefer = any -o $ldbm_prefer = gdbm ; then AC_CHECK_LIB(gdbm, gdbm_open,[ ldbm_use=$ldbm_prefer ldbm_prefer=found - LIBDB="-lgdbm" - AC_DEFINE(LDBM_USE_GDBM,1) -dnl LDAP_DEFS="$LDAP_DEFS -DLDBM_USE_GDBM" + LDBM_LIB="-lgdbm" +dnl AC_DEFINE(LDBM_USE_GDBM,1) + LDBM_DEFS="$LDAP_DEFS -DLDBM_USE_GDBM" ]) fi if test $ldbm_prefer = any -o $ldbm_prefer = ndbm ; then AC_CHECK_LIB(dbm,dbm_open,[ ldbm_use=ndbm ldbm_prefer=found - LIBDB="-ldbm" - AC_DEFINE(LDBM_USE_NDBM,1) -dnl LDAP_DEFS="$LDAP_DEFS -DLDBM_USE_NDBM" + LDBM_LIB="-ldbm" +dnl AC_DEFINE(LDBM_USE_NDBM,1) + LDBM_DEFS="$LDAP_DEFS -DLDBM_USE_NDBM" ]) fi @@ -243,9 +245,6 @@ dnl LDAP_DEFS="$LDAP_DEFS -DLDBM_USE_NDBM" fi fi -AC_SUBST(LDAP_DEFS) -AC_SUBST(LIBDB) - # ud needs termcap (should insert check here) LIBTERMCAP="-ltermcap" AC_SUBST(LIBTERMCAP) @@ -322,6 +321,17 @@ AC_REPLACE_FUNCS(strdup) # Check Configuration CF_SYS_ERRLIST +AC_SUBST(LDAP_DEFS) +AC_SUBST(LDAP_LIBS) +AC_SUBST(LDAPD_DEFS) +AC_SUBST(LDAPD_LIBS) +AC_SUBST(SLAPD_DEFS) +AC_SUBST(SLAPD_LIBS) +AC_SUBST(SLUPPD_DEFS) +AC_SUBST(SLUPPD_LIBS) +AC_SUBST(LDBM_DEFS) +AC_SUBST(LDBM_LIBS) + dnl AC_OUTPUT( \ dnl clients/tools/Makefile:build/top.mk:clients/tools/Makefile.in:build/rules.mk \ dnl clients/ud/Makefile:build/top.mk:clients/ud/Makefile.in:build/rules.mk \ diff --git a/include/portable.h.in b/include/portable.h.in index b7382dd804..0216c4a40e 100644 --- a/include/portable.h.in +++ b/include/portable.h.in @@ -82,29 +82,20 @@ /* define this to remove -lldap cache support */ #undef LDAP_NOCACHE +/* define this for LDAP referrals support */ +#undef LDAP_REFERRALS + /* define this for phonetic support */ -#undef LDAP_PHONETIC +#undef SLAPD_PHONETIC /* define this to use SLAPD shell backend */ -#undef SLAPD_SHELL +/* #undef SLAPD_SHELL */ /* define this to use SLAPD passwd backend */ -#undef SLAPD_PASSWD +/* #undef SLAPD_PASSWD */ /* define this to use SLAPD LDBM backend */ -#undef SLAPD_LDBM - -/* define this to use DBBTREE w/ LDBM backend */ -#undef LDBM_USE_DBBTREE - -/* define this to use DBHASH w/ LDBM backend */ -#undef LDBM_USE_DBHASH - -/* define this to use GDBM w/ LDBM backend */ -#undef LDBM_USE_GDBM - -/* define this to use NDBM w/ LDBM backend */ -#undef LDBM_USE_NDBM +/* #undef SLAPD_LDBM */ /* Define if you have the gethostname function. */ #undef HAVE_GETHOSTNAME diff --git a/libraries/libldbm/Makefile.in b/libraries/libldbm/Makefile.in index ffc9d96928..8d66c7d7f7 100644 --- a/libraries/libldbm/Makefile.in +++ b/libraries/libldbm/Makefile.in @@ -6,6 +6,10 @@ XPROGRAMS = testldbm SRCS = ldbm.c OBJS = ldbm.o +XDEFS = @LDBM_DEFS@ +XLIBS = @LDBM_LIBS@ + LIBS = -L$(LDAP_LIBDIR) -lavl $(AC_LIBS) + testldbm: libldbm.a testldbm.o $(CC) $(LDFLAGS) -o $@ testldbm.o $(LIBS)