From e034386cd845408a7c31a699d5b26065eabccd48 Mon Sep 17 00:00:00 2001 From: Sascha Schumann Date: Thu, 4 May 2000 20:17:22 +0000 Subject: [PATCH] Move the generating empty deps stuff into fastgen.sh. The .deps files are only used by Makefiles which are created by fastgen.sh, so fastgen is the natural place to create them. The "portable dirname" regex has been changed to remove any number of trailing slashes. Just in case. :) git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@85139 13f79535-47bb-0310-9956-ffa450edef68 --- build/fastgen.sh | 5 +++-- build/rules.mk | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/build/fastgen.sh b/build/fastgen.sh index 3dc252df089..66097e3606b 100755 --- a/build/fastgen.sh +++ b/build/fastgen.sh @@ -72,8 +72,7 @@ fi for makefile in $@; do echo "creating $makefile" -# portable dirname - dir=`echo $makefile|sed -e 's%[^/][^/]*$%%' -e 's%/$%%'` + dir=`echo $makefile|sed 's%/*[^/][^/]*$%%'` test -d "$dir/" || $mkdir_p "$dir/" (cat < $makefile + touch "$top_builddir/$dir/.deps" + done diff --git a/build/rules.mk b/build/rules.mk index 98c3cfdc0b0..6d1c8a92d5a 100644 --- a/build/rules.mk +++ b/build/rules.mk @@ -113,7 +113,6 @@ distclean-recursive depend-recursive clean-recursive all-recursive install-recur ok=yes; \ target="$$target-p"; \ fi; \ - if test ! -f $$i/.deps; then touch $$i/.deps; fi; \ (cd $$i && $(MAKE) $$target) || exit 1; \ done; \ if test "$$otarget" = "all" && test -z '$(targets)'; then ok=yes; fi;\ @@ -131,7 +130,7 @@ install-p: $(targets) $(install_targets) distclean-p depend-p clean-p: depend: depend-recursive - gcc -MM $(INCLUDES) $(EXTRA_INCLUDES) $(DEFS) $(CPPFLAGS) $(srcdir)/*.c > $(builddir)/.deps + gcc -MM $(INCLUDES) $(EXTRA_INCLUDES) $(DEFS) $(CPPFLAGS) $(srcdir)/*.c > $(builddir)/.deps || true # test "`echo *.c`" = '*.c' || perl $(top_srcdir)/build/mkdep.perl $(CPP) $(INCLUDES) $(EXTRA_INCLUDES) *.c > .deps clean: clean-recursive clean-x -- 2.47.3