[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200610215100.256599-9-irogers@google.com>
Date: Wed, 10 Jun 2020 14:50:58 -0700
From: Ian Rogers <irogers@...gle.com>
To: Peter Zijlstra <peterz@...radead.org>,
Ingo Molnar <mingo@...hat.com>,
Arnaldo Carvalho de Melo <acme@...nel.org>,
Mark Rutland <mark.rutland@....com>,
Alexander Shishkin <alexander.shishkin@...ux.intel.com>,
Jiri Olsa <jolsa@...hat.com>,
Namhyung Kim <namhyung@...nel.org>,
Andi Kleen <ak@...ux.intel.com>,
Jin Yao <yao.jin@...ux.intel.com>,
John Garry <john.garry@...wei.com>,
Adrian Hunter <adrian.hunter@...el.com>,
linux-kernel@...r.kernel.org
Cc: Stephane Eranian <eranian@...gle.com>,
Ian Rogers <irogers@...gle.com>
Subject: [PATCH 08/10] perf expr: Avoid implicit lex function declaration
Add include and a dependency.
Signed-off-by: Ian Rogers <irogers@...gle.com>
---
tools/perf/util/Build | 2 ++
tools/perf/util/expr.y | 2 ++
2 files changed, 4 insertions(+)
diff --git a/tools/perf/util/Build b/tools/perf/util/Build
index 43f3310827c4..dc5b80ae39ac 100644
--- a/tools/perf/util/Build
+++ b/tools/perf/util/Build
@@ -211,6 +211,8 @@ $(OUTPUT)util/expr-bison.c $(OUTPUT)util/expr-bison.h: util/expr.y
$(Q)$(call echo-cmd,bison)$(BISON) -v $< -d $(PARSER_DEBUG_BISON) \
-o $(OUTPUT)util/expr-bison.c -p expr_
+$(OUTPUT)util/expr-bison.o: $(OUTPUT)util/expr-flex.h
+
$(OUTPUT)util/pmu-flex.c $(OUTPUT)util/pmu-flex.h: util/pmu.l $(OUTPUT)util/pmu-bison.c
$(call rule_mkdir)
$(Q)$(call echo-cmd,flex)$(FLEX) -o $(OUTPUT)util/pmu-flex.c \
diff --git a/tools/perf/util/expr.y b/tools/perf/util/expr.y
index bf3e898e3055..f34a5e544a41 100644
--- a/tools/perf/util/expr.y
+++ b/tools/perf/util/expr.y
@@ -39,6 +39,8 @@
%type <num> expr if_expr
%{
+#include "expr-flex.h"
+
static void expr_error(double *final_val __maybe_unused,
struct expr_parse_ctx *ctx __maybe_unused,
void *scanner,
--
2.27.0.278.ge193c7cf3a9-goog
Powered by blists - more mailing lists