Subject: Re: [PATCH v3 7/7] perf expr: Migrate expr ids table to a hashmap

From: Arnaldo Carvalho de Melo <[email-masked]>
Date: Mon, 18 May 2020 13:11:37 -0300

Em Mon, May 18, 2020 at 01:06:48PM -0300, Arnaldo Carvalho de Melo escreveu:
> Em Mon, May 18, 2020 at 09:03:45AM -0700, Ian Rogers escreveu:
> > On Mon, May 18, 2020 at 8:45 AM Arnaldo Carvalho de Melo wrote:
> > this build issue sounds like this patch is missing:
> > https://lore.kernel.org/lkml/[email-masked]/
> > The commit message there could have explicitly said having this
> > #include causes the conflicting definitions between perf's debug.h and
> > libbpf_internal.h's definitions of pr_info, etc.
> 
> yeah, understood, but I'm not processing patches for tools/lib/bpf/,
> Daniel is, I'll only get that one later, then we can go back to the way
> you structured it. Just an extra bit of confusion in this process ;-)

So, thiis is failing on all alpine Linux containers:

  CC       /tmp/build/perf/util/metricgroup.o
  CC       /tmp/build/perf/util/header.o
In file included from util/metricgroup.c:25:0:
/git/linux/tools/lib/api/fs/fs.h:16:0: error: "FS" redefined [-Werror]
 #define FS(name)    \
 ^
In file included from /git/linux/tools/perf/util/hashmap.h:16:0,
                 from util/expr.h:11,
                 from util/metricgroup.c:14:
/usr/include/bits/reg.h:28:0: note: this is the location of the previous definition
 #define FS     25
 ^
  CC       /tmp/build/perf/util/callchain.o
  CC       /tmp/build/perf/util/values.o
  CC       /tmp/build/perf/util/debug.o
  CC       /tmp/build/perf/util/fncache.o
cc1: all warnings being treated as errors
mv: can't rename '/tmp/build/perf/util/.metricgroup.o.tmp': No such file or directory
/git/linux/tools/build/Makefile.build:96: recipe for target '/tmp/build/perf/util/metricgroup.o' failed

I'll check that soon,

- Arnaldo