]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
verbose.mk: Fix warning from GNU Make 4.4
authorAlejandro Colomar <alx@kernel.org>
Sun, 2 Apr 2023 13:03:54 +0000 (15:03 +0200)
committerAlejandro Colomar <alx@kernel.org>
Sun, 2 Apr 2023 13:06:54 +0000 (15:06 +0200)
While '$(V).SILENT:' is a common idiom in make, it may be more explicit
to put '.SILENT:' inside a conditional.  Since we already used the
conditional for something else, it's not a big change.  As a nice side
effect, vim now recognizes it and highlights it as a special target.

With the old code, GNU Make 4.4 reported a warning about undefined
variables:

lib/verbose.mk:18: warning: undefined variable 'V'

Signed-off-by: Alejandro Colomar <alx@kernel.org>
lib/verbose.mk

index 38180804ffc8ed46c2f35192d5f1b17014516c1f..af2fe154f12e75bd5740cb2722177508a9b9e4d2 100644 (file)
@@ -12,10 +12,8 @@ ifdef V
 HIDE_ERR :=
 else
 HIDE_ERR := 2>/dev/null
+.SILENT:
 endif
 
 
-$(V).SILENT:
-
-
 endif  # MAKEFILE_VERBOSE_INCLUDED