Re: Building 4.14 LTS kernel with GCC 8

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Greg,

It seems 4.14.76 perf compile is still broken for GCC 8 and we can't
find "77f18153c080855e1c3fb520ca31a4e61530121d: perf tools: Fix
snprint
warnings for gcc 8" in the changelog.

Was it missed by any chance?

Thanks,
Ignat
On Thu, Oct 11, 2018 at 11:26 AM Ignat Korchagin <ignat@xxxxxxxxxxxxxx> wrote:
>
> > That's odd, given that the moved code is the same...
>
> Yes, I agree. But I didn't debug why exactly it happens, because there
> is an upstream patch already, which "fixes" it somehow.
>
> Thanks,
> Ignat
> On Thu, Oct 11, 2018 at 11:17 AM Greg KH <greg@xxxxxxxxx> wrote:
> >
> > On Thu, Oct 11, 2018 at 11:12:38AM +0100, Ignat Korchagin wrote:
> > > On Thu, Oct 11, 2018 at 8:29 AM Greg KH <greg@xxxxxxxxx> wrote:
> > >
> > > > Why is this last commit needed?
> > >
> > > Without it I get the following compile error (Debian 9 with
> > > self-compiled GCC 8):
> > >
> > > builtin-script.c: In function 'get_script_path':
> > > builtin-script.c:2139:20: error: '%s' directive writing up to 255
> > > bytes into a region of size between 0 and 4095
> > > [-Werror=format-overflow=]
> > >   sprintf(path, "%s/%s", base_path, dent->d_name);
> > >                     ^~
> > > In file included from /usr/include/stdio.h:938,
> > >                  from util/event.h:6,
> > >                  from util/debug.h:9,
> > >                  from builtin-script.c:6:
> > > /usr/include/x86_64-linux-gnu/bits/stdio2.h:33:10: note:
> > > '__builtin___sprintf_chk' output between 2 and 4352 bytes into a
> > > destination of size 4096
> > >    return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
> > >           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > >        __bos (__s), __fmt, __va_arg_pack ());
> > >        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > > builtin-script.c:2139:20: error: '%s' directive writing up to 255
> > > bytes into a region of size between 0 and 4095
> > > [-Werror=format-overflow=]
> > >   sprintf(path, "%s/%s", base_path, dent->d_name);
> > >                     ^~
> > > In file included from /usr/include/stdio.h:938,
> > >                  from util/event.h:6,
> > >                  from util/debug.h:9,
> > >                  from builtin-script.c:6:
> > > /usr/include/x86_64-linux-gnu/bits/stdio2.h:33:10: note:
> > > '__builtin___sprintf_chk' output between 2 and 4352 bytes into a
> > > destination of size 4096
> > >    return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
> > >           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > >        __bos (__s), __fmt, __va_arg_pack ());
> > >        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > > builtin-script.c: In function 'find_scripts':
> > > builtin-script.c:2139:20: error: '%s' directive writing up to 255
> > > bytes into a region of size between 0 and 4095
> > > [-Werror=format-overflow=]
> > >   sprintf(path, "%s/%s", base_path, dent->d_name);
> > >                     ^~
> > > In file included from /usr/include/stdio.h:938,
> > >                  from util/event.h:6,
> > >                  from util/debug.h:9,
> > >                  from builtin-script.c:6:
> > > /usr/include/x86_64-linux-gnu/bits/stdio2.h:33:10: note:
> > > '__builtin___sprintf_chk' output between 2 and 4352 bytes into a
> > > destination of size 4096
> > >    return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
> > >           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > >        __bos (__s), __fmt, __va_arg_pack ());
> > >        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > > builtin-script.c:2139:20: error: '%s' directive writing up to 255
> > > bytes into a region of size between 0 and 4095
> > > [-Werror=format-overflow=]
> > >   sprintf(path, "%s/%s", base_path, dent->d_name);
> > >                     ^~
> > > In file included from /usr/include/stdio.h:938,
> > >                  from util/event.h:6,
> > >                  from util/debug.h:9,
> > >                  from builtin-script.c:6:
> > > /usr/include/x86_64-linux-gnu/bits/stdio2.h:33:10: note:
> > > '__builtin___sprintf_chk' output between 2 and 4352 bytes into a
> > > destination of size 4096
> > >    return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
> > >           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > >        __bos (__s), __fmt, __va_arg_pack ());
> > >        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> > > cc1: all warnings being treated as errors
> >
> > That's odd, given that the moved code is the same...
> >
> > Oh well, I'll go queue it up, thanks,
> >
> > greg k-h



[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux