Messages in this thread | | | Date | Mon, 5 Jun 2017 14:12:36 -0300 | From | Arnaldo Carvalho de Melo <> | Subject | Re: [PATCH 1/3] perf tools: Set proper module name when build-id event found |
| |
Em Wed, May 31, 2017 at 09:01:03PM +0900, Namhyung Kim escreveu: > +++ b/tools/perf/util/header.c > @@ -1469,8 +1469,16 @@ static int __event_process_build_id(struct build_id_event *bev, > > dso__set_build_id(dso, &bev->build_id); > > - if (!is_kernel_module(filename, cpumode)) > - dso->kernel = dso_type; > + if (dso_type != DSO_TYPE_USER) { > + struct kmod_path m = {}; > +
This fails in several distros, among them centos:7, debian:8
CC /tmp/build/perf/util/header.o util/header.c: In function '__event_process_build_id': util/header.c:1473:11: error: missing initializer for field 'name' of 'struct kmod_path' [-Werror=missing-field-initializers] struct kmod_path m = {}; ^ In file included from util/symbol.h:24:0, from util/evsel.h:10, from util/evlist.h:11, from util/header.c:19: util/dso.h:249:8: note: 'name' declared here char *name; ^ cc1: all warnings being treated as errors mv: cannot stat '/tmp/build/perf/util/.header.o.tmp': No such file or directory make[4]: *** [/tmp/build/perf/util/header.o] Error 1 make[3]: *** [util] Error 2 make[3]: *** Waiting for unfinished jobs....
centos:5, centos:6, debian:7 have a slightly different message:
CC /tmp/build/perf/util/callchain.o cc1: warnings being treated as errors util/header.c: In function '__event_process_build_id': util/header.c:1473: warning: missing initializer util/header.c:1473: warning: (near initialization for 'm.name') MKDIR /tmp/build/perf/util/ CC /tmp/build/perf/util/values.o mv: cannot stat `/tmp/build/perf/util/.header.o.tmp': No such file or directory
I'll fix this.
- Arnaldo
| |