diff options
author | Namhyung Kim <namhyung.kim@lge.com> | 2012-09-28 05:31:59 -0400 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2012-09-28 20:07:36 -0400 |
commit | 29a0fc9b2b6084e7a8810481df62a0fa496d8957 (patch) | |
tree | b14fcf9ba9c906ae969daa242057b391bd93ba81 /tools/perf/Makefile | |
parent | e4898336a1b4d8a259663d15b12f359b6c2887a2 (diff) |
perf tools: Convert to LIBELF_SUPPORT
For building perf without libelf, we can set NO_LIBELF=1 as a argument
of make. It then defines NO_LIBELF_SUPPORT macro for C code to do the
proper handling. However it usually used in a negative semantics -
e.g. #ifndef - so we saw double negations which can be misleading.
Convert it to a positive form to make it more readable.
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Cc: Ingo Molnar <mingo@kernel.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/r/1348824728-14025-4-git-send-email-namhyung@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Diffstat (limited to 'tools/perf/Makefile')
-rw-r--r-- | tools/perf/Makefile | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/perf/Makefile b/tools/perf/Makefile index 9cd49130f438..1df09175d8d4 100644 --- a/tools/perf/Makefile +++ b/tools/perf/Makefile | |||
@@ -503,8 +503,6 @@ ifneq ($(OUTPUT),) | |||
503 | endif | 503 | endif |
504 | 504 | ||
505 | ifdef NO_LIBELF | 505 | ifdef NO_LIBELF |
506 | BASIC_CFLAGS += -DNO_LIBELF_SUPPORT | ||
507 | |||
508 | EXTLIBS := $(filter-out -lelf,$(EXTLIBS)) | 506 | EXTLIBS := $(filter-out -lelf,$(EXTLIBS)) |
509 | 507 | ||
510 | # Remove ELF/DWARF dependent codes | 508 | # Remove ELF/DWARF dependent codes |
@@ -519,9 +517,10 @@ BUILTIN_OBJS := $(filter-out $(OUTPUT)builtin-probe.o,$(BUILTIN_OBJS)) | |||
519 | LIB_OBJS += $(OUTPUT)util/symbol-minimal.o | 517 | LIB_OBJS += $(OUTPUT)util/symbol-minimal.o |
520 | 518 | ||
521 | else # NO_LIBELF | 519 | else # NO_LIBELF |
520 | BASIC_CFLAGS += -DLIBELF_SUPPORT | ||
522 | 521 | ||
523 | ifneq ($(call try-cc,$(SOURCE_ELF_MMAP),$(FLAGS_COMMON)),y) | 522 | ifeq ($(call try-cc,$(SOURCE_ELF_MMAP),$(FLAGS_COMMON)),y) |
524 | BASIC_CFLAGS += -DLIBELF_NO_MMAP | 523 | BASIC_CFLAGS += -DLIBELF_MMAP |
525 | endif | 524 | endif |
526 | 525 | ||
527 | ifndef NO_DWARF | 526 | ifndef NO_DWARF |