From: Nathan Scott Date: Fri, 5 Apr 2002 06:19:28 +0000 (+0000) Subject: incorporate Andreas' makedepend realtive-path change everywhere. X-Git-Tag: v2.1.0~42 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4df72956c13d47a39c40f5ac59fef524430e6315;p=thirdparty%2Fxfsprogs-dev.git incorporate Andreas' makedepend realtive-path change everywhere. --- diff --git a/include/buildrules b/include/buildrules index e4c6af2b4..4db3b289b 100644 --- a/include/buildrules +++ b/include/buildrules @@ -66,10 +66,16 @@ $(_FORCE): depend : $(CFILES) $(HFILES) $(SUBDIRS_MAKERULE) - touch dep - $(MAKEDEPEND) -fdep -- $(CFLAGS) -- $(CFILES) + touch .dep + $(MAKEDEPEND) -f - -- $(CFLAGS) -- $(CFILES) | \ + $(SED) -e 's,`pwd`,$(TOPDIR),g' \ + -e 's, */[^ ]*,,g' \ + -e '/^[^ ]*: *$$/d' \ + -e '/^#.*/d' -e '/^ *$$/d' \ + > .dep + test -s .dep || rm -f .dep # Include dep, but only if it exists -ifeq ($(shell test -f dep && echo dep), dep) -include dep +ifeq ($(shell test -f .dep && echo .dep), .dep) +include .dep endif