[CRIU] [PATCH] nmk: remove no-print-directory from MAKEFLAGS

Kir Kolyshkin kir at openvz.org
Thu Feb 25 14:36:13 PST 2016


The problem with --no-print-directory set by default is when we
run :make from vim and compilation performed by a sub-make fails,
vim can't figure out the correct path to a file with error, so
instead of jumping to the position of the first error, it opens
a new empty file.

When make prints "Entering directory ..." and "Leaving directory ..."
messages, vim :make works as intended.

[Alternatively, we could add -w to $(MAKE) invocations where needed,
but the problem is --no-print-directory overrides -w even if -w comes
later in the options list, so -w is not working. I was also thinking
about detecting whether we are running from vim, but when we'll need
to add detection for emacs etc., so let's keep things simple.]

Cc: Andrey Vagin <avagin at openvz.org>
Cc: Cyrill Gorcunov <gorcunov at openvz.org>
Signed-off-by: Kir Kolyshkin <kir at openvz.org>
---
 scripts/nmk/scripts/include.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/nmk/scripts/include.mk b/scripts/nmk/scripts/include.mk
index 546b56b..1ba6529 100644
--- a/scripts/nmk/scripts/include.mk
+++ b/scripts/nmk/scripts/include.mk
@@ -30,7 +30,7 @@ endif
 
 # Do not use make's built-in rules and variables
 # (this increases performance and avoids hard-to-debug behaviour).
-MAKEFLAGS += -rR --no-print-directory
+MAKEFLAGS += -rR
 export MAKEFLAGS
 
 # Avoid funny character set dependencies.
-- 
2.5.0



More information about the CRIU mailing list