From: Ken Raeburn Date: Fri, 13 Sep 2002 23:06:15 +0000 (+0000) Subject: Permit building against either the in-tree version of db2 or a system version X-Git-Tag: krb5-1.3-alpha1~396 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=71b09c0dd54810322d34ad03d1ae24457dfa1629;p=krb5.git Permit building against either the in-tree version of db2 or a system version specified at configure time. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14855 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/ChangeLog b/src/ChangeLog index a451755e8..c8b1cd465 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -3,6 +3,8 @@ * aclocal.m4 (KRB5_AC_CHOOSE_DB): New macro. (CONFIG_RULES): Invoke it. + * configure.in: Configure util/db2 only if we're going to use it. + 2002-09-03 Ken Raeburn * aclocal.m4 (KRB_INCLUDE): Put in-tree include dirs before diff --git a/src/config/ChangeLog b/src/config/ChangeLog index 761a0deac..922a62ca0 100644 --- a/src/config/ChangeLog +++ b/src/config/ChangeLog @@ -1,3 +1,11 @@ +2002-09-13 Ken Raeburn + + * pre.in (DB_DEPLIB-k5, DB_DEPLIB-sys, DB_DEPS-sys, DB_DEPS-k5, + DB_DEPS-redirect): New variables. + (DB_DEPLIB, DB_DEPS): Select from them. + (DB_LIB): Substitute from configure script. + (COM_ERR_VERSION, SS_VERSION, DB_VERSION): New variables. + 2002-09-10 Ken Raeburn * post.in (depfix2.sed): Pass srcdir and BUILDTOP as additional diff --git a/src/config/pre.in b/src/config/pre.in index b9237ffde..3ce05bda0 100644 --- a/src/config/pre.in +++ b/src/config/pre.in @@ -203,7 +203,9 @@ DEPLIBEXT=@DEPLIBEXT@ KADMCLNT_DEPLIB = $(TOPLIBD)/libkadm5clnt$(DEPLIBEXT) KADMSRV_DEPLIB = $(TOPLIBD)/libkadm5srv$(DEPLIBEXT) KDB5_DEPLIB = $(TOPLIBD)/libkdb5$(DEPLIBEXT) -DB_DEPLIB = $(TOPLIBD)/libdb$(DEPLIBEXT) +DB_DEPLIB = $(DB_DEPLIB-@DB_VERSION@) +DB_DEPLIB-k5 = $(TOPLIBD)/libdb$(DEPLIBEXT) +DB_DEPLIB-sys = GSSRPC_DEPLIB = $(TOPLIBD)/libgssrpc$(DEPLIBEXT) GSS_DEPLIB = $(TOPLIBD)/libgssapi_krb5$(DEPLIBEXT) KRB4_DEPLIB = @KRB4_DEPLIB@ # $(TOPLIBD)/libkrb4$(DEPLIBEXT) @@ -231,14 +233,23 @@ KADM_COMM_DEPLIBS = $(GSSRPC_DEPLIBS) $(KDB5_DEPLIBS) $(GSSRPC_DEPLIBS) KADMSRV_DEPLIBS = $(KADMSRV_DEPLIB) $(KDB5_DEPLIBS) $(KADM_COMM_DEPLIBS) KADMCLNT_DEPLIBS = $(KADMCLNT_DEPLIB) $(KADM_COMM_DEPLIBS) -# Header file dependencies we might override someday. +# Header file dependencies we might override. # See util/depfix.sed. +# Also see depend-verify-* in post.in, which wants to confirm that we're using +# the in-tree versions. +COM_ERR_VERSION = @COM_ERR_VERSION@ COM_ERR_DEPS = $(COM_ERR_DEPS-@COM_ERR_VERSION@) -COM_ERR_DEPS-sys = # empty +COM_ERR_DEPS-sys = COM_ERR_DEPS-k5 = $(BUILDTOP)/include/com_err.h +SS_VERSION = @SS_VERSION@ SS_DEPS = $(SS_DEPS-@SS_VERSION@) SS_DEPS-sys = SS_DEPS-k5 = $(BUILDTOP)/include/ss/ss.h $(BUILDTOP)/include/ss/ss_err.h +DB_VERSION = @DB_VERSION@ +DB_DEPS = $(DB_DEPS-@DB_HEADER_VERSION@) +DB_DEPS-sys = +DB_DEPS-k5 = $(BUILDTOP)/include/db.h $(BUILDTOP)/include/db-config.h +DB_DEPS-redirect = $(BUILDTOP)/include/db.h # LIBS gets substituted in... e.g. -lnsl -lsocket @@ -249,7 +260,7 @@ SS_LIB = $(SS_LIB-@SS_VERSION@) SS_LIB-sys = @SS_LIB@ SS_LIB-k5 = $(TOPLIBD)/libss.a KDB5_LIB = -lkdb5 -DB_LIB = -ldb +DB_LIB = @DB_LIB@ KRB5_LIB = $(KRB5_LIB_@LIB_LINK_OPT@) KRB5_LIB_libopt = -lkrb5 diff --git a/src/configure.in b/src/configure.in index e08bbffcb..45f1bd5bd 100644 --- a/src/configure.in +++ b/src/configure.in @@ -86,7 +86,11 @@ fi if test "$SS_VERSION" = k5 ; then AC_CONFIG_SUBDIRS(util/ss) fi -AC_CONFIG_SUBDIRS(util/profile util/pty util/db2 include lib/crypto lib/krb5 lib/des425) +AC_CONFIG_SUBDIRS(util/profile util/pty) +if test "$DB_VERSION" = k5 ; then + AC_CONFIG_SUBDIRS(util/db2) +fi +AC_CONFIG_SUBDIRS(include lib/crypto lib/krb5 lib/des425) if test -n "$KRB4_LIB"; then AC_CONFIG_SUBDIRS(lib/krb4) fi diff --git a/src/include/ChangeLog b/src/include/ChangeLog index ef9ff2685..0dec7e62d 100644 --- a/src/include/ChangeLog +++ b/src/include/ChangeLog @@ -1,3 +1,11 @@ +2002-09-13 Ken Raeburn + + * Makefile.in (maybe-make-db.h-sys, maybe-make-db.h-k5): New + targets, doing nothing. + (maybe-make-db.h-redirect): New target, creates db.h using + @DB_HEADER@. + (all-unix): Depend on maybe-make-db.h-@DB_HEADER_VERSION@. + 2002-09-03 Ken Raeburn * fake-addrinfo.h (gaiptr, faiptr, gniptr): Delete duplicate diff --git a/src/include/Makefile.in b/src/include/Makefile.in index 9f067fff5..6c6efa06f 100644 --- a/src/include/Makefile.in +++ b/src/include/Makefile.in @@ -15,6 +15,15 @@ all-windows:: $(MAKE) -$(MFLAGS) cd .. +all-unix:: maybe-make-db.h-@DB_HEADER_VERSION@ + +maybe-make-db.h-k5: + : db.h will be installed by util/db2 +maybe-make-db.h-sys: + : fall back to system db.h +maybe-make-db.h-redirect: + test -r db.h || echo '#include <@DB_HEADER@>' > db.h + krb5/autoconf.h: $(srcdir)/krb5/autoconf.h.in (cd krb5; $(MAKE) autoconf.h) $(srcdir)/krb5/autoconf.h.in: $(srcdir)/krb5/autoconf.stmp diff --git a/src/util/ChangeLog b/src/util/ChangeLog index 69dddcce9..5eb494bdf 100644 --- a/src/util/ChangeLog +++ b/src/util/ChangeLog @@ -1,5 +1,8 @@ 2002-09-13 Ken Raeburn + * Makefile.in (MY_SUBDIRS): Use MAYBE_DB_@DB_VERSION@. + (MAYBE_DB_k5, MAYBE_DB_sys): New variables. + * depfix.sed: Replace db2 headers with $(DB_DEPS). 2002-09-10 Ken Raeburn diff --git a/src/util/Makefile.in b/src/util/Makefile.in index 28280135e..1176f2a38 100644 --- a/src/util/Makefile.in +++ b/src/util/Makefile.in @@ -7,14 +7,16 @@ mydir=util ##WIN32### below in the 'all-windows' target anyways, so just hide this. ##WIN32##!if 0 MY_SUBDIRS=$(MAYBE_ET_@COM_ERR_VERSION@) $(MAYBE_SS_@SS_VERSION@) \ - profile pty db2 send-pr + profile pty $(MAYBE_DB_@DB_VERSION@) send-pr ##WIN32##!endif BUILDTOP=$(REL).. MAYBE_ET_k5 = et MAYBE_SS_k5 = ss +MAYBE_DB_k5 = db2 MAYBE_ET_sys = MAYBE_SS_sys = +MAYBE_DB_sys = MAC_SUBDIRS = profile et