aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/Makefile
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2010-01-12 08:58:29 -0200
committerGreg Kroah-Hartman <gregkh@suse.de>2011-05-09 15:55:29 -0700
commitddb02625a519ffb60a41c8e8bf53b6a3ac68b350 (patch)
tree301b304b26a8463a28eb681c4a9ccdb9b4fab039 /tools/perf/Makefile
parentd14085b73f362c8cdcc20a39276f5fcf9c8979f0 (diff)
perf tools: Move QUIET_STDERR def to before first use
commit 830395188fae5f4028fa3c38ab1b031aae18a64c upstream. QUIET_STDERR is used when detecting if -fstack-protector-all can be used. Noticed while building the perf tools on a Debian PARISC64 machine. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Cc: Frédéric Weisbecker <fweisbec@gmail.com> Cc: Mike Galbraith <efault@gmx.de> Cc: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Paul Mackerras <paulus@samba.org> LKML-Reference: <1263293910-8484-1-git-send-email-acme@infradead.org> Signed-off-by: Ingo Molnar <mingo@elte.hu> [bwh: Backport to 2.6.32] Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'tools/perf/Makefile')
-rw-r--r--tools/perf/Makefile11
1 files changed, 6 insertions, 5 deletions
diff --git a/tools/perf/Makefile b/tools/perf/Makefile
index 1b2f98f77ac2..848b4c6376a1 100644
--- a/tools/perf/Makefile
+++ b/tools/perf/Makefile
@@ -252,6 +252,12 @@ PTHREAD_LIBS = -lpthread
# explicitly what architecture to check for. Fix this up for yours..
SPARSE_FLAGS = -D__BIG_ENDIAN__ -D__powerpc__
+ifeq ($(V), 2)
+ QUIET_STDERR = ">/dev/null"
+else
+ QUIET_STDERR = ">/dev/null 2>&1"
+endif
+
ifeq ($(shell sh -c "echo 'int foo(void) {char X[2]; return 3;}' | $(CC) -x c -c -Werror -fstack-protector-all - -o /dev/null "$(QUIET_STDERR)" && echo y"), y)
CFLAGS := $(CFLAGS) -fstack-protector-all
endif
@@ -397,11 +403,6 @@ BUILTIN_OBJS += builtin-trace.o
PERFLIBS = $(LIB_FILE)
-ifeq ($(V), 2)
- QUIET_STDERR = ">/dev/null"
-else
- QUIET_STDERR = ">/dev/null 2>&1"
-endif
#
# Platform specific tweaks
#