[Pkg-xen-devel] Bug#853710: Bug#853710: xen: ftbfs with GCC-7

Hans van Kranenburg hans at knorrie.org
Thu Jan 11 22:01:46 UTC 2018


On 11/01/2018 22:42, Hans van Kranenburg wrote:
> Hey,
> 
> On 11/01/2018 18:59, peter green wrote:
>>> I think the compiler is simply wrong to complain about this.
>> If you are going to build with options like "-Wall -Werror" then you
>> have to expect the compiler to be bitchy. You should be able to make
>> this particular warning non-fatal by adding -Wno-error=int-in-bool-context
> 
> Thanks for the help.
> 
> First thing that's going to happen to Xen in Debian unstable is moving
> to Xen 4.10, which compiles fine with gcc-7.
> 
> If I point my pbuilder (debian unstable) at the current package that's
> in the archive, it indeed explodes halfway:
> 
> xenlockprof.c: In function 'main':
> xenlockprof.c:100:53: error: '%s' directive writing up to 39 bytes into
> a region of size between 17 and 37 [-Werror=format-overflow=]
>              sprintf(name, "unknown type(%d) %d lock %s", data[j].type,
>                                                      ^~
> xenlockprof.c:100:13: note: 'sprintf' output between 24 and 83 bytes
> into a destination of size 60
>              sprintf(name, "unknown type(%d) %d lock %s", data[j].type,
>              ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>                      data[j].idx, data[j].name);
>                      ~~~~~~~~~~~~~~~~~~~~~~~~~~
> cc1: all warnings being treated as errors

Actually, this is a different error, which looks a bit like a buffer
overflow type of thing?

I'm not a C code compile hero (yet?), just started out helping on the
Xen team. So maybe someone else can better comment on this specific thing.

> So, FWIW, I think we can close this case, since buster will definitely
> not ship with Xen 4.8 but newer.

Or maybe we're allowed to close it when the new upload is being done,
and you want to have it open until then? In that case there's no way
it'll slip through.

Just wanted to let know that during the preparations of upgrading the
package to Xen 4.10 I have been able to build successfully targeting
unstable so far.

Thanks,
Hans



More information about the Pkg-xen-devel mailing list