diff options
3 files changed, 13 insertions, 14 deletions
diff --git a/Makefile b/Makefile
index c3326b7ddc43..130fdbf67200 100644
--- a/Makefile
+++ b/Makefile
@@ -243,14 +243,8 @@ cleanworld:
# Handle the user-driven targets, using the source relative mk files.
-.if !(!empty(.MAKEFLAGS:M-n) && ${.MAKEFLAGS:M-n} == "-n")
-# skip this for -n to avoid changing previous behavior of
-# 'make -n buildworld' etc. Using -n -n will run it.
tinderbox toolchains kernel-toolchains: .MAKE
${_+_}@cd ${.CURDIR}; ${_MAKE} ${.TARGET}
# The historic default "all" target creates files which may cause stale
diff --git a/UPDATING b/UPDATING
index baff1f13605b..1095ba6ea5d1 100644
@@ -31,6 +31,12 @@ NOTE TO PEOPLE WHO THINK THAT FreeBSD 11.x IS SLOW:
disable the most expensive debugging functionality run
"ln -s 'abort:false,junk:false' /etc/malloc.conf".)
+ The build previously allowed using 'make -n' to not recurse into
+ sub-directories while showing what commands would be executed, and
+ 'make -n -n' to recursively show commands. Now 'make -n' will recurse
+ and 'make -N' will not.
If you specify SENDMAIL_MC or SENDMAIL_CF in make.conf, mergemaster
and etcupdate will now use this file. A custom sendmail.cf is now
diff --git a/share/mk/sys.mk b/share/mk/sys.mk
index e8f4892cd99d..b6c75b6f96a6 100644
--- a/share/mk/sys.mk
+++ b/share/mk/sys.mk
@@ -145,13 +145,12 @@ ECHODIR ?= true
-.if defined(.PARSEDIR)
-# _+_ appears to be a workaround for the special src .MAKE not working.
-# setting it to + interferes with -N
-_+_ ?=
-.elif !empty(.MAKEFLAGS:M-n) && ${.MAKEFLAGS:M-n} == "-n"
-# the check above matches only a single -n, so -n -n will result
-# in _+_ = +
+.if ${.MAKEFLAGS:M-N}
+# bmake -N is supposed to skip executing anything but it does not skip
+# exeucting '+' commands. The '+' feature is used where .MAKE
+# is not safe for the entire target. -N is intended to skip building sub-makes
+# so it executing '+' commands is not right. Work around the bug by not
+# setting '+' when -N is used.
_+_ ?=
_+_ ?= +