From 3b076df5e0739ee7934ae9e02ceb73c4f34484fb Mon Sep 17 00:00:00 2001 From: Ken Raeburn Date: Thu, 15 Aug 2002 01:45:55 +0000 Subject: [PATCH] * lib.in ($(SUBDIROBJLISTS) and .SH/.PF variants): Depend on recursion. Use extra dummy target in case the variable is empty. * post.in (ALL_DEP_SRCS): New variable, includes SRCS and EXTRADEPSRCS. (.d): Depend on and use $(ALL_DEP_SRCS). * pre.in (all-unix, all-recurse, all-postrecurse): Make each stage depend on the previous, rather than having all-unix depend on each. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14719 dc483132-0cff-0310-8789-dd5450dbe970 --- src/config/ChangeLog | 12 ++++++++++++ src/config/lib.in | 2 ++ src/config/post.in | 10 +++++++--- src/config/pre.in | 4 ++-- 4 files changed, 23 insertions(+), 5 deletions(-) diff --git a/src/config/ChangeLog b/src/config/ChangeLog index ed5761cbe..03a4c2227 100644 --- a/src/config/ChangeLog +++ b/src/config/ChangeLog @@ -1,3 +1,15 @@ +2002-08-14 Ken Raeburn + + * lib.in ($(SUBDIROBJLISTS) and .SH/.PF variants): Depend on + recursion. Use extra dummy target in case the variable is + empty. + * post.in (ALL_DEP_SRCS): New variable, includes SRCS and + EXTRADEPSRCS. + (.d): Depend on and use $(ALL_DEP_SRCS). + * pre.in (all-unix, all-recurse, all-postrecurse): Make each stage + depend on the previous, rather than having all-unix depend on + each. + 2002-07-17 Ken Raeburn * pre.in (DYN_DEPLIB): Removed. diff --git a/src/config/lib.in b/src/config/lib.in index ad37262b3..3d9d86a72 100644 --- a/src/config/lib.in +++ b/src/config/lib.in @@ -76,6 +76,8 @@ SHLIB_EXPFLAGS=@SHLIB_EXPFLAGS@ SHOBJLISTS=$(STOBJLISTS:.ST=.SH) PFOBJLISTS=$(STOBJLISTS:.ST=.PF) +dummy-target-1 $(SUBDIROBJLISTS) $(SUBDIROBJLISTS:.ST=.SH) $(SUBDIROBJLISTS:.ST=.PF): all-recurse + lib$(LIB)$(STLIBEXT): $(STOBJLISTS) $(RM) $@ @echo "building static $(LIB) library" diff --git a/src/config/post.in b/src/config/post.in index ae4b2c844..7a08e857b 100644 --- a/src/config/post.in +++ b/src/config/post.in @@ -2,14 +2,18 @@ check-windows:: -.d: $(SRCS) +ALL_DEP_SRCS= $(SRCS) $(EXTRADEPSRCS) + +# be sure to check ALL_DEP_SRCS against *what it would be if SRCS and +# EXTRADEPSRCS are both empty* +.d: $(ALL_DEP_SRCS) if test "$(srcdir)" = "." ; then \ echo 1>&2 error: cannot build dependencies with srcdir=. ; \ echo 1>&2 "(can't distinguish generated files from source files)" ; \ exit 1 ; \ fi - if test -n "$(SRCS)" ; then \ - $(CC) -M $(ALL_CFLAGS) $(SRCS) > .dtmp || exit 1 ; \ + if test "$(ALL_DEP_SRCS)" != " " ; then \ + $(CC) -M $(ALL_CFLAGS) $(ALL_DEP_SRCS) > .dtmp || exit 1 ; \ mv -f .dtmp .d ; \ else \ touch .d ; \ diff --git a/src/config/pre.in b/src/config/pre.in index 889af4432..b35f4d70c 100644 --- a/src/config/pre.in +++ b/src/config/pre.in @@ -12,8 +12,8 @@ install:: install-$(WHAT) check:: check-$(WHAT) -all-unix:: all-prerecurse -all-unix:: all-recurse +all-recurse: all-prerecurse +all-postrecurse:: all-recurse all-unix:: all-postrecurse all-prerecurse:: -- 2.26.2