diff options
author | David Ahern <dsahern@gmail.com> | 2013-10-29 12:43:15 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2013-11-05 08:08:03 -0500 |
commit | 5febff0066b8111785d58903b54d414e9ec6a3d0 (patch) | |
tree | 3b6ec01323e49aab8e929fc3dbd4252b8c050a63 /tools/perf | |
parent | 87419c9afff1431d4b62b388baf6bfa07e0b14ff (diff) |
tools/perf/build: Fix detection of non-core features
feature_check needs to be invoked through call, and LDFLAGS may not be
set so quotes are needed.
Thanks to Jiri for spotting the quotes around LDFLAGS; that one was
driving me nuts with the upcoming timerfd feature detection.
Signed-off-by: David Ahern <dsahern@gmail.com>
Reviewed-by: Jiri Olsa <jolsa@redhat.com>
Tested-by: Jiri Olsa <jolsa@redhat.com>
Acked-by: Ingo Molnar <mingo@kernel.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1383064996-20933-1-git-send-email-dsahern@gmail.com
[ Fixed conflict with 8a0c4c2843d3 ("perf tools: Fix libunwind build and feature detection for 32-bit build") ]
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf')
-rw-r--r-- | tools/perf/config/Makefile | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/perf/config/Makefile b/tools/perf/config/Makefile index be8bb9a77287..58b2d37ae23a 100644 --- a/tools/perf/config/Makefile +++ b/tools/perf/config/Makefile | |||
@@ -98,7 +98,7 @@ endif | |||
98 | 98 | ||
99 | feature_check = $(eval $(feature_check_code)) | 99 | feature_check = $(eval $(feature_check_code)) |
100 | define feature_check_code | 100 | define feature_check_code |
101 | feature-$(1) := $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS)" LDFLAGS=$(LDFLAGS) LIBUNWIND_LIBS="$(LIBUNWIND_LIBS)" -C config/feature-checks test-$1 >/dev/null 2>/dev/null && echo 1 || echo 0) | 101 | feature-$(1) := $(shell $(MAKE) OUTPUT=$(OUTPUT_FEATURES) CFLAGS="$(EXTRA_CFLAGS)" LDFLAGS="$(LDFLAGS)" LIBUNWIND_LIBS="$(LIBUNWIND_LIBS)" -C config/feature-checks test-$1 >/dev/null 2>/dev/null && echo 1 || echo 0) |
102 | endef | 102 | endef |
103 | 103 | ||
104 | feature_set = $(eval $(feature_set_code)) | 104 | feature_set = $(eval $(feature_set_code)) |
@@ -235,7 +235,7 @@ CFLAGS += -I$(LIB_INCLUDE) | |||
235 | CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE | 235 | CFLAGS += -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -D_GNU_SOURCE |
236 | 236 | ||
237 | ifndef NO_BIONIC | 237 | ifndef NO_BIONIC |
238 | $(feature_check,bionic) | 238 | $(call feature_check,bionic) |
239 | ifeq ($(feature-bionic), 1) | 239 | ifeq ($(feature-bionic), 1) |
240 | BIONIC := 1 | 240 | BIONIC := 1 |
241 | EXTLIBS := $(filter-out -lrt,$(EXTLIBS)) | 241 | EXTLIBS := $(filter-out -lrt,$(EXTLIBS)) |
@@ -479,15 +479,15 @@ else | |||
479 | CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT | 479 | CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT |
480 | else | 480 | else |
481 | ifneq ($(feature-libbfd), 1) | 481 | ifneq ($(feature-libbfd), 1) |
482 | $(feature_check,liberty) | 482 | $(call feature_check,liberty) |
483 | ifeq ($(feature-liberty), 1) | 483 | ifeq ($(feature-liberty), 1) |
484 | EXTLIBS += -lbfd -liberty | 484 | EXTLIBS += -lbfd -liberty |
485 | else | 485 | else |
486 | $(feature_check,liberty-z) | 486 | $(call feature_check,liberty-z) |
487 | ifeq ($(feature-liberty-z), 1) | 487 | ifeq ($(feature-liberty-z), 1) |
488 | EXTLIBS += -lbfd -liberty -lz | 488 | EXTLIBS += -lbfd -liberty -lz |
489 | else | 489 | else |
490 | $(feature_check,cplus-demangle) | 490 | $(call feature_check,cplus-demangle) |
491 | ifeq ($(feature-cplus-demangle), 1) | 491 | ifeq ($(feature-cplus-demangle), 1) |
492 | EXTLIBS += -liberty | 492 | EXTLIBS += -liberty |
493 | CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT | 493 | CFLAGS += -DHAVE_CPLUS_DEMANGLE_SUPPORT |