perf build failure with v6.11-rc4 (commit 4bbe60029319 ("perf daemon: Fix the build on 32-bit architectures"))

From: LEROY Christophe
Date: Wed Aug 21 2024 - 06:52:28 EST


Got the following build failure on v6.11-rc4, see
https://github.com/chleroy/linux/actions/runs/10485680041/job/29042302519

builtin-daemon.c: In function 'cmd_session_list':
Error: builtin-daemon.c:692:16: error: format '%llu' expects argument of
type 'long long unsigned int', but argument 4 has type 'long int'
[-Werror=format=]
692 | fprintf(out, "%c%" PRIu64,
| ^~~~~
693 | /* session up time */
694 | csv_sep, (curr - daemon->start) / 60);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long int
In file included from builtin-daemon.c:3:
/usr/powerpc-linux-gnu/include/inttypes.h:105:34: note: format string is
defined here
105 | # define PRIu64 __PRI64_PREFIX "u"
Error: builtin-daemon.c:704:17: error: format '%llu' expects argument of
type 'long long unsigned int', but argument 3 has type 'long int'
[-Werror=format=]
704 | fprintf(out, " up: %" PRIu64 " minutes\n",
| ^~~~~~~~~~~~~~
705 | (curr - daemon->start) / 60);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long int
In file included from builtin-daemon.c:3:
/usr/powerpc-linux-gnu/include/inttypes.h:105:34: note: format string is
defined here
105 | # define PRIu64 __PRI64_PREFIX "u"
Error: builtin-daemon.c:731:17: error: format '%llu' expects argument of
type 'long long unsigned int', but argument 4 has type 'long int'
[-Werror=format=]
731 | fprintf(out, "%c%" PRIu64,
| ^~~~~
732 | /* session up time */
733 | csv_sep, (curr - session->start) / 60);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long int
In file included from builtin-daemon.c:3:
/usr/powerpc-linux-gnu/include/inttypes.h:105:34: note: format string is
defined here
105 | # define PRIu64 __PRI64_PREFIX "u"
Error: builtin-daemon.c:749:17: error: format '%llu' expects argument of
type 'long long unsigned int', but argument 3 has type 'long int'
[-Werror=format=]
749 | fprintf(out, " up: %" PRIu64 " minutes\n",
| ^~~~~~~~~~~~~~
750 | (curr - session->start) / 60);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| long int
In file included from builtin-daemon.c:3:
/usr/powerpc-linux-gnu/include/inttypes.h:105:34: note: format string is
defined here
105 | # define PRIu64 __PRI64_PREFIX "u"


Christophe