Current master fails to build on i686-pc-linux-gnu
Simon Marchi
simark@simark.ca
Tue Dec 24 21:51:00 GMT 2019
On 2019-12-24 3:44 p.m., Ruslan Kabatsayev wrote:
> Hello,
>
> Building current master of binutils-gdb (commit ebd1c6d1d30; git-blame
> points to commits e35000a7f8be and d0922fcf02c6) results in some
> -Werror=format= errors on i686-pc-linux-gnu:
>
> In file included from dwarf2read.c:47:0:
> dwarf2read.c: In function âbool is_valid_DW_AT_defaulted(ULONGEST)â:
> complaints.h:38:40: error: format â%luâ expects argument of type âlong
> unsigned intâ, but argument 2 has type âULONGEST {aka long long
> unsigned int}â [-Werror=format=]
> complaint_internal (FMT, ##__VA_ARGS__); \
> ^
> dwarf2read.c:15490:3: note: in expansion of macro âcomplaintâ
> complaint (_("unrecognized DW_AT_defaulted value (%lu)"), value);
> ^~~~~~~~~
> dwarf2read.c: In function âbool
> is_valid_DW_AT_calling_convention_for_type(ULONGEST)â:
> complaints.h:38:40: error: format â%luâ expects argument of type âlong
> unsigned intâ, but argument 2 has type âULONGEST {aka long long
> unsigned int}â [-Werror=format=]
> complaint_internal (FMT, ##__VA_ARGS__); \
> ^
> dwarf2read.c:15869:7: note: in expansion of macro âcomplaintâ
> complaint (_("unrecognized DW_AT_calling_convention value "
> ^~~~~~~~~
> dwarf2read.c: In function âbool
> is_valid_DW_AT_calling_convention_for_subroutine(ULONGEST)â:
> complaints.h:38:40: error: format â%luâ expects argument of type âlong
> unsigned intâ, but argument 2 has type âULONGEST {aka long long
> unsigned int}â [-Werror=format=]
> complaint_internal (FMT, ##__VA_ARGS__); \
> ^
> dwarf2read.c:15895:7: note: in expansion of macro âcomplaintâ
> complaint (_("unrecognized DW_AT_calling_convention value "
> ^~~~~~~~~
>
> Regards,
> Ruslan
Sorry about that, I failed to catch it during review. The fix is simple,
these should use pulongest (value) with the format specifier "%s". I don't
really have time right now to fix it. If you'd like to make a patch, please
go ahead and push it.
Simon
More information about the Gdb-patches
mailing list