From f4fbac193108ea063ad3cbf2c39de5845208901d Mon Sep 17 00:00:00 2001 From: Bryan Drewery Date: Sun, 13 Nov 2016 00:10:59 +0000 Subject: [PATCH] DIRDEPS_BUILD: Don't hook 'beforebuild' into 'all' in MAKELEVEL 0. This was a mistake in r295641, but is effectively prevented from being a problem due to r296699 preventing 'make all' from being usable at MAKELEVEL 0 for DIRDEPS_BUILD. MFC after: 2 weeks Sponsored by: Dell EMC Isilon --- share/mk/bsd.init.mk | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/share/mk/bsd.init.mk b/share/mk/bsd.init.mk index b7a45d9ac43..35cd3b1a90d 100644 --- a/share/mk/bsd.init.mk +++ b/share/mk/bsd.init.mk @@ -15,10 +15,6 @@ ____: .endif .include .MAIN: all -beforebuild: .PHONY .NOTMAIN -.if !defined(_SKIP_BUILD) -all: beforebuild .WAIT -.endif .if ${.MAKE.LEVEL:U1} == 0 && ${BUILD_AT_LEVEL0:Uyes:tl} == "no" && !make(clean*) # this tells lib.mk and prog.mk to not actually build anything @@ -28,6 +24,11 @@ _SKIP_BUILD = not building at level 0 .warning ${_SKIP_BUILD} .endif +beforebuild: .PHONY .NOTMAIN +.if !defined(_SKIP_BUILD) +all: beforebuild .WAIT +.endif + .if ${MK_META_MODE} == "yes" .if !exists(/dev/filemon) && \ ${UPDATE_DEPENDFILE:Uyes:tl} != "no" && !defined(NO_FILEMON) && \