From: David Ahern <dsahern@gmail.com>
To: acme@ghostprotocols.net, linux-kernel@vger.kernel.org
Cc: David Ahern <dsahern@gmail.com>, Borislav Petkov <bp@alien8.de>,
Frederic Weisbecker <fweisbec@gmail.com>,
Ingo Molnar <mingo@kernel.org>, Jiri Olsa <jolsa@redhat.com>,
Namhyung Kim <namhyung@kernel.org>,
Peter Zijlstra <a.p.zijlstra@chello.nl>,
Stephane Eranian <eranian@google.com>
Subject: [PATCH 18/23] perf: deprecate LIBELF_SUPPORT in favor of CONFIG_LIBELF
Date: Mon, 1 Apr 2013 21:54:32 -0600 [thread overview]
Message-ID: <1364874877-5618-19-git-send-email-dsahern@gmail.com> (raw)
In-Reply-To: <1364874877-5618-1-git-send-email-dsahern@gmail.com>
Signed-off-by: David Ahern <dsahern@gmail.com>
Cc: Arnaldo Carvalho de Melo <acme@ghostprotocols.net>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
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>
Cc: Stephane Eranian <eranian@google.com>
---
tools/perf/Makefile | 2 --
tools/perf/builtin-inject.c | 3 ++-
tools/perf/perf.c | 2 +-
tools/perf/util/generate-cmdlist.sh | 4 ++--
tools/perf/util/map.c | 3 ++-
tools/perf/util/symbol.h | 4 ++--
6 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/tools/perf/Makefile b/tools/perf/Makefile
index cc44818..f9847db 100644
--- a/tools/perf/Makefile
+++ b/tools/perf/Makefile
@@ -584,8 +584,6 @@ ifneq ($(OUTPUT),)
endif
ifdef CONFIG_LIBELF
- BASIC_CFLAGS += -DLIBELF_SUPPORT
-
FLAGS_LIBELF=$(ALL_CFLAGS) $(ALL_LDFLAGS) $(EXTLIBS)
ifeq ($(call try-cc,$(SOURCE_ELF_MMAP),$(FLAGS_LIBELF),-DLIBELF_MMAP),y)
BASIC_CFLAGS += -DLIBELF_MMAP
diff --git a/tools/perf/builtin-inject.c b/tools/perf/builtin-inject.c
index 84ad6ab..92e8012 100644
--- a/tools/perf/builtin-inject.c
+++ b/tools/perf/builtin-inject.c
@@ -17,6 +17,7 @@
#include "util/build-id.h"
#include "util/parse-options.h"
+#include <linux/kconfig.h>
#include <linux/list.h>
@@ -229,7 +230,7 @@ static int perf_event__inject_buildid(struct perf_tool *tool,
* account this as unresolved.
*/
} else {
-#ifdef LIBELF_SUPPORT
+#ifdef CONFIG_LIBELF
pr_warning("no symbols found in %s, maybe "
"install a debug package?\n",
al.map->dso->long_name);
diff --git a/tools/perf/perf.c b/tools/perf/perf.c
index f7fcf78..0919ee1 100644
--- a/tools/perf/perf.c
+++ b/tools/perf/perf.c
@@ -50,7 +50,7 @@ static struct cmd_struct commands[] = {
{ "version", cmd_version, 0 },
{ "script", cmd_script, 0 },
{ "sched", cmd_sched, 0 },
-#ifdef LIBELF_SUPPORT
+#ifdef CONFIG_LIBELF
{ "probe", cmd_probe, 0 },
#endif
{ "kmem", cmd_kmem, 0 },
diff --git a/tools/perf/util/generate-cmdlist.sh b/tools/perf/util/generate-cmdlist.sh
index 3ac3803..8c039f6 100755
--- a/tools/perf/util/generate-cmdlist.sh
+++ b/tools/perf/util/generate-cmdlist.sh
@@ -22,7 +22,7 @@ do
}' "Documentation/perf-$cmd.txt"
done
-echo "#ifdef LIBELF_SUPPORT"
+echo "#ifdef CONFIG_LIBELF"
sed -n -e 's/^perf-\([^ ]*\)[ ].* full.*/\1/p' command-list.txt |
sort |
while read cmd
@@ -35,5 +35,5 @@ do
p
}' "Documentation/perf-$cmd.txt"
done
-echo "#endif /* LIBELF_SUPPORT */"
+echo "#endif /* CONFIG_LIBELF */"
echo "};"
diff --git a/tools/perf/util/map.c b/tools/perf/util/map.c
index 6fcb9de..80f351f 100644
--- a/tools/perf/util/map.c
+++ b/tools/perf/util/map.c
@@ -11,6 +11,7 @@
#include "strlist.h"
#include "vdso.h"
#include "build-id.h"
+#include <linux/kconfig.h>
#include <linux/string.h>
const char *map_type__name[MAP__NR_TYPES] = {
@@ -165,7 +166,7 @@ int map__load(struct map *map, symbol_filter_t filter)
pr_warning(", continuing without symbols\n");
return -1;
} else if (nr == 0) {
-#ifdef LIBELF_SUPPORT
+#ifdef CONFIG_LIBELF
const size_t len = strlen(name);
const size_t real_len = len - sizeof(DSO__DELETED);
diff --git a/tools/perf/util/symbol.h b/tools/perf/util/symbol.h
index cd284dc..3875d40 100644
--- a/tools/perf/util/symbol.h
+++ b/tools/perf/util/symbol.h
@@ -14,7 +14,7 @@
#include "build-id.h"
#include <linux/kconfig.h>
-#ifdef LIBELF_SUPPORT
+#ifdef CONFIG_LIBELF
#include <libelf.h>
#include <gelf.h>
#endif
@@ -172,7 +172,7 @@ struct symsrc {
int fd;
enum dso_binary_type type;
-#ifdef LIBELF_SUPPORT
+#ifdef CONFIG_LIBELF
Elf *elf;
GElf_Ehdr ehdr;
--
1.7.10.1
next prev parent reply other threads:[~2013-04-02 3:57 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-02 3:54 [PATCH 00/23] perf: integrate with kconfig and CONFIG driven features David Ahern
2013-04-02 3:54 ` [PATCH 01/23] perf: initial infrasructure for kconfig David Ahern
2013-04-02 8:22 ` Paul Bolle
2013-04-02 15:09 ` David Ahern
2013-04-02 3:54 ` [PATCH 02/23] perf: make perl support based on CONFIG_LIBPERL David Ahern
2013-04-02 3:54 ` [PATCH 03/23] perf: make python support based on CONFIG_LIBPYTHON David Ahern
2013-04-02 3:54 ` [PATCH 04/23] perf: make gtk2 support based on CONFIG_GTK2 David Ahern
2013-04-02 3:54 ` [PATCH 05/23] perf: make newt support based on CONFIG_NEWT David Ahern
2013-04-02 3:54 ` [PATCH 06/23] perf: remove NEWT_SUPPORT in favor of CONFIG_NEWT David Ahern
2013-04-02 3:54 ` [PATCH 07/23] perf: remove GTK2_SUPPORT in favor of CONFIG_GTK2 David Ahern
2013-04-02 3:54 ` [PATCH 08/23] perf: make elf support based on CONFIG_LIBELF David Ahern
2013-04-02 3:54 ` [PATCH 09/23] perf: make cfi unwind support based on CONFIG_LIBUNWIND David Ahern
2013-04-02 9:32 ` Paul Bolle
2013-04-02 15:20 ` David Ahern
2013-04-04 8:02 ` Paul Bolle
2013-04-02 3:54 ` [PATCH 10/23] perf: make demangle support based on CONFIG_DEMANGLE David Ahern
2013-04-02 9:26 ` Paul Bolle
2013-04-02 3:54 ` [PATCH 11/23] perf: make dwarf support based on CONFIG_DWARF David Ahern
2013-04-02 3:54 ` [PATCH 12/23] perf: add BIONIC config option David Ahern
2013-04-02 3:54 ` [PATCH 13/23] perf: make numa support based on CONFIG_LIBNUMA David Ahern
2013-04-02 3:54 ` [PATCH 14/23] perf: make backtrace support based on CONFIG_BACKTRACE David Ahern
2013-04-02 3:54 ` [PATCH 15/23] perf: make libaudit support based on CONFIG_LIBAUDIT David Ahern
2013-04-02 3:54 ` [PATCH 16/23] perf: consolidate CONFIG_LIBUNWIND checks in Makefile David Ahern
2013-04-02 3:54 ` [PATCH 17/23] perf: remove LIBUNWIND_SUPPORT in favor of CONFIG_LIBUNWIND David Ahern
2013-04-02 3:54 ` David Ahern [this message]
2013-04-02 3:54 ` [PATCH 19/23] perf: deprecate DWARF_SUPPORT in favor of CONFIG_DWARF David Ahern
2013-04-02 3:54 ` [PATCH 20/23] perf: consolidate CONFIG_LIBELF checks in Makefile David Ahern
2013-04-02 9:37 ` Paul Bolle
2013-04-02 15:21 ` David Ahern
2013-04-02 3:54 ` [PATCH 21/23] perf: consolidate CONFIG_DWARF " David Ahern
2013-04-02 3:54 ` [PATCH 22/23] perf: only add elf to EXTLIBS if CONFIG_LIBELF is set David Ahern
2013-04-02 3:54 ` [PATCH 23/23] perf: only add elf-based object files " David Ahern
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1364874877-5618-19-git-send-email-dsahern@gmail.com \
--to=dsahern@gmail.com \
--cc=a.p.zijlstra@chello.nl \
--cc=acme@ghostprotocols.net \
--cc=bp@alien8.de \
--cc=eranian@google.com \
--cc=fweisbec@gmail.com \
--cc=jolsa@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=namhyung@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox