[PATCH] perf tools: Hide feature test result on make -s

From: Namhyung Kim
Date: Tue Jan 29 2013 - 01:48:36 EST


Other commands like QUIET_CC already honour -s option of make so the
try-cc should do the same. Make it really quiet if -s option is given
and ignore V=1 (it's only meaningful without -s option).

Reported-by: Thomas Backlund <tmb@xxxxxxxxxx>
Signed-off-by: Namhyung Kim <namhyung@xxxxxxxxxx>
---
tools/perf/config/utilities.mak | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/tools/perf/config/utilities.mak b/tools/perf/config/utilities.mak
index e5413125e6bb..9d202fce1306 100644
--- a/tools/perf/config/utilities.mak
+++ b/tools/perf/config/utilities.mak
@@ -181,10 +181,13 @@ _gea_err = $(if $(1),$(error Please set '$(1)' appropriately))

# try-cc
# Usage: option = $(call try-cc, source-to-build, cc-options, msg)
-ifndef V
TRY_CC_OUTPUT= > /dev/null 2>&1
-endif
+ifneq ($(findstring $(MAKEFLAGS),s),s)
TRY_CC_MSG=echo " CHK $(3)" 1>&2;
+ifdef V
+TRY_CC_OUTPUT=
+endif
+endif

try-cc = $(shell sh -c \
'TMP="$(OUTPUT)$(TMPOUT).$$$$"; \
--
1.7.11.7

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/