tools/perf/util/Build b/tools/perf/util/Build enables implicit function declarations using -Wno-implicit-function-declaration, which likely will fail to have the desired effect with future GCC versions. I've got a patch to fix this which I'm trying to upstream, but I have trouble posting it, and the perf upstream maintainer seems to have a non-mainline tree that happens to have semantic conflicts with my changes. Reproducible: Always
Created attachment 1961933 [details] kernel-tools-c99.patch I still hope to upstream this patch eventually, after rebasing it on top of the appropriate -next tree. The maintainer receives my email messages, so vger dropping the patch should not be an issue.
Created attachment 1962028 [details] kernel-tools-c99.patch New version, rebased on perf-next. Apparently still dropped by vger.kernel.org.
This bug appears to have been reported against 'rawhide' during the Fedora Linux 39 development cycle. Changing version to 39.
Fixed upstream via: commit ddc8e4c966923ad1137790817157c8a5f0301aec Author: Ian Rogers <irogers> Date: Thu Jul 27 23:49:16 2023 -0700 perf build: Disable fewer bison warnings If bison is version 3.8.2, reduce the number of bison C warnings disabled. Earlier bison versions have all C warnings disabled. Avoid implicit declarations of yylex by adding the declaration in the C file. A header can't be included as a circular dependency would occur due to the lexer using the bison defined tokens. Committer notes: Some recent versions of gcc and clang (noticed on Alpine Linux 3.17, edge, clearlinux, fedora 37, etc. Signed-off-by: Ian Rogers <irogers> Cc: Adrian Hunter <adrian.hunter> Cc: Alexander Shishkin <alexander.shishkin.com> Cc: Andrii Nakryiko <andrii> Cc: Eduard Zingerman <eddyz87> Cc: Gaosheng Cui <cuigaosheng1> Cc: Ingo Molnar <mingo> Cc: Jiri Olsa <jolsa> Cc: Kan Liang <kan.liang.com> Cc: Mark Rutland <mark.rutland> Cc: Namhyung Kim <namhyung> Cc: Nathan Chancellor <nathan> Cc: Nick Desaulniers <ndesaulniers> Cc: Peter Zijlstra <peterz> Cc: Rob Herring <robh> Cc: Tom Rix <trix> Cc: bpf.org Cc: llvm.dev Link: https://lore.kernel.org/r/20230728064917.767761-6-irogers@google.com Signed-off-by: Arnaldo Carvalho de Melo <acme>