From 30175d7650d3777e57aea5b4d6cbb90e49c6c94e Mon Sep 17 00:00:00 2001 From: Julio Merino Date: Thu, 30 Oct 2014 22:07:29 +0000 Subject: [PATCH] Use the right depend file for each program. bsd.progs.mk generates a separate depend file for every program being built, but then it does not properly tell each submake to use those individual files. Properly propagate the depend file to use. Discovered while preparing the update of atf to 0.21 and noticing that the test programs were not being relinked to the new library. This change is "make tinderbox" clean. --- share/mk/bsd.progs.mk | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/share/mk/bsd.progs.mk b/share/mk/bsd.progs.mk index e72231319eee..64fae5f48c80 100644 --- a/share/mk/bsd.progs.mk +++ b/share/mk/bsd.progs.mk @@ -90,12 +90,16 @@ x.$p= PROG_CXX=$p $p ${p}_p: .PHONY .MAKE (cd ${.CURDIR} && ${MAKE} -f ${MAKEFILE} _RECURSING_PROGS= \ - SUBDIR= PROG=$p ${x.$p}) + SUBDIR= PROG=$p \ + DEPENDFILE=.depend.$p .MAKE.DEPENDFILE=.depend.$p \ + ${x.$p}) .for t in ${PROGS_TARGETS:O:u} $p.$t: .PHONY .MAKE (cd ${.CURDIR} && ${MAKE} -f ${MAKEFILE} _RECURSING_PROGS= \ - SUBDIR= PROG=$p ${x.$p} ${@:E}) + SUBDIR= PROG=$p \ + DEPENDFILE=.depend.$p .MAKE.DEPENDFILE=.depend.$p \ + ${x.$p} ${@:E}) .endfor .endfor