Re: [PATCH] perf probe: Fix build failure

From: Masami Hiramatsu
Date: Wed Jan 13 2010 - 23:48:50 EST


Hi,

Thank you, the patch code looks good to me.

Li Zefan wrote:
> builtin-probe.c:121: error: 'opt_show_lines' defined but not used

Please add some comment for explanation, like:

This build error occurs when compiling perf-tools without dwarf
support (no libdwarf).

>
> Signed-off-by: Li Zefan <lizf@xxxxxxxxxxxxxx>
> ---
> tools/perf/builtin-probe.c | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/tools/perf/builtin-probe.c b/tools/perf/builtin-probe.c
> index 1d3a99e..9be8063 100644
> --- a/tools/perf/builtin-probe.c
> +++ b/tools/perf/builtin-probe.c
> @@ -118,6 +118,7 @@ static int opt_del_probe_event(const struct option *opt __used,
> return 0;
> }
>
> +#ifndef NO_LIBDWARF
> static int opt_show_lines(const struct option *opt __used,
> const char *str, int unset __used)
> {
> @@ -127,6 +128,8 @@ static int opt_show_lines(const struct option *opt __used,
> session.show_lines = true;
> return 0;
> }
> +#endif
> +
> /* Currently just checking function name from symbol map */
> static void evaluate_probe_point(struct probe_point *pp)
> {

--
Masami Hiramatsu

Software Engineer
Hitachi Computer Products (America), Inc.
Software Solutions Division

e-mail: mhiramat@xxxxxxxxxx

--
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/