aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBryan Drewery <bdrewery@FreeBSD.org>2016-02-24 17:19:09 +0000
committerBryan Drewery <bdrewery@FreeBSD.org>2016-02-24 17:19:09 +0000
commit68add213442714579fd5bdc73b52a8df0dbbb9cb (patch)
tree8e293aaa5bd14537e40b96fb23a5a924b2ae7820
parentd7beff082b71fb7d1b4ca94d3cc44d64bbbfb2d6 (diff)
downloadsrc-68add213442714579fd5bdc73b52a8df0dbbb9cb.tar.gz
src-68add213442714579fd5bdc73b52a8df0dbbb9cb.zip
FAST_DEPEND: Don't waste time generating an empty .depend file.
The .depend file will still be generated if _EXTRADEPEND is used. The target is kept with a dependency on DPSRCS though so that 'make depend' will generate all files. Sponsored by: EMC / Isilon Storage Division
Notes
Notes: svn path=/head/; revision=295986
-rw-r--r--share/mk/bsd.dep.mk4
-rw-r--r--sys/conf/kern.post.mk2
2 files changed, 2 insertions, 4 deletions
diff --git a/share/mk/bsd.dep.mk b/share/mk/bsd.dep.mk
index ec2ac1fc58ef..2b9301eed7d6 100644
--- a/share/mk/bsd.dep.mk
+++ b/share/mk/bsd.dep.mk
@@ -246,6 +246,8 @@ MKDEP_CXXFLAGS= ${CXXFLAGS:M-nostdinc*} ${CXXFLAGS:M-[BIDU]*} \
.endif # ${MK_FAST_DEPEND} == "no"
DPSRCS+= ${SRCS}
+# FAST_DEPEND will only generate a .depend if _EXTRADEPEND is used but
+# the target is created to allow 'make depend' to generate files.
${DEPENDFILE}: ${DPSRCS}
.if ${MK_FAST_DEPEND} == "no"
rm -f ${DEPENDFILE}
@@ -260,8 +262,6 @@ ${DEPENDFILE}: ${DPSRCS}
${.ALLSRC:M*.cc} ${.ALLSRC:M*.C} ${.ALLSRC:M*.cpp} ${.ALLSRC:M*.cxx}
.else
.endif
-.else
- : > ${.TARGET}
.endif # ${MK_FAST_DEPEND} == "no"
.if target(_EXTRADEPEND)
_EXTRADEPEND: .USE
diff --git a/sys/conf/kern.post.mk b/sys/conf/kern.post.mk
index f1ab570edac1..f16acda4ab0a 100644
--- a/sys/conf/kern.post.mk
+++ b/sys/conf/kern.post.mk
@@ -278,8 +278,6 @@ ${__obj}: ${OBJS_DEPEND_GUESS.${__obj}}
${MAKE} -V SFILES_CDDL | \
CC="${_MKDEPCC}" xargs mkdep -a -f ${.TARGET}.tmp ${ZFS_ASM_CFLAGS}
mv ${.TARGET}.tmp ${.TARGET}
-.else
- : > ${.TARGET}
.endif
_ILINKS= machine