[Mesa-dev] [PATCH] Android: disable warnings causing errors
Eric Engestrom
eric.engestrom at imgtec.com
Mon Dec 4 15:50:53 UTC 2017
On Thursday, 2017-11-30 14:20:08 +0000, Emil Velikov wrote:
> On 29 November 2017 at 18:12, Rob Herring <robh at kernel.org> wrote:
> > On Wed, Nov 29, 2017 at 11:01 AM, Emil Velikov <emil.l.velikov at gmail.com> wrote:
> >> On 27 November 2017 at 19:36, Rob Herring <robh at kernel.org> wrote:
> >>> AOSP master has changed the build default to -Werror making all the
> >>> warnings errors. Override that with -Wno-error.
> >>>
> >> For both Mesa and libdrm patches
> >>
> >> Reviewed-by: Emil Velikov <emil.velikov at collabora.com>
> >>
> >> Mildly related:
> >> Quick grep|sort|unique through your build log shows the following.
> >> Some quick ideas, I haven't looked which one comes from where.
> >
> > I have...
> >
> >>
> >> 4 -Wdeprecated-declarations]
> >> 60 -Wdeprecated-register]
> >
> > These are generated from bison, yacc or something. I'm not sure how to
> > fix. That's where I ran the other way.
> >
> Seems like the toolchain used is pretty ancient.
>
> Flex:
> commit 8091dc907663673d9e0295c57fa446bdd38e9fab
> Author: Yuri <yuri at tsoft.com>
> Date: Thu Jul 17 14:07:30 2014 -0700
>
> Removed deprecated 'register' storage class specifier.
>
>
> Bison:
> commit cb530ce9e2687c6b1e51b77a29a9062ad52166b4
> Author: Paul Eggert <eggert at cs.ucla.edu>
> Date: Fri Jan 21 19:12:32 2005 +0000
>
> (YYCOPY, yystpcpy, yyparse): Remove "register".
>
>
> >> 6 -Wenum-conversion]
> >> 3 -Wformat]
> >> Should be trivial.
> >>
> >> 14 -Wmissing-braces]
> >> I'm fairly convinced this comes from the universal initializer {0}
> >> Just silence it?
> >>
> >> 44 -Wdelete-non-virtual-dtor]
> >
> > I posted a patch a while back trying to fix this, but it actually
> > broke things at runtime.
> >
> I think Jonathan and Marc (both CC'd) have patches for OpenBSD [1] and
> VcXsrv [2], respectively.
> Perhaps one could start a separate thread and bounce off ideas/patches?
>
> [1] https://github.com/jonathangray/mesa/commit/c8f4c68261a0ddf9aaa5c9b9990d8b6e4e4d49a9
> [2] quick diff against between local checkouts
> https://paste.pound-python.org/show/O8UiZkQtiHMvR9SegVlV/
>
>
> >> 4 -Wshift-negative-value]
> >> 20 -Wsometimes-uninitialized]
> >> 4 -Wuninitialized]
> >> Potential bugs, or compiler snafu?
> >>
> >> 52 -Wasm-operand-widths]
> >> 4 -Wconstant-logical-operand]
> >> 16 -Wgnu-variable-sized-type-not-at-end]
> >> 2 -Wmacro-redefined]
> >> 56 -Woverloaded-virtual]
> >
> > Patch posted for these too.
> >
> >> 26 -Wtautological-constant-out-of-range-compare]
> >> 1 -Wuser-defined-warnings]
> >> Meh?
> >>
> >> Addressing the [clang] mismatched-tags and toggling the warning back
> >> on shouldn't be too bad?
> >
> > How many are clang/Android specific? It would be hopeless to re-enable
> > Werror if autotools/meson builds are not kept warning free. Maybe
> > those builds need to be stricter.
> >
> Having Werror will backfire IMHO. Although adding a few more toggles
> to the Linux builds won't be a bad idea.
> I was wondering if we can throw Wextra in the mix, but that will
> introduce way too many warnings.
>
> Gert addresses a few of those already, and [IIRC] Eric was pondering
> about the -Wunused* in src/egl.
Indeed, but it turned out to be a much bigger task than anticipated;
I already have dozens of commits in a local branch (at home, where
I haven't been able to spend much time lately), and I'm nowhere near
finished, there are tons of unused variables/parameters all over the
place, and it trickles all the way up and down.
Don't expect me to send this series before Christmas :)
> Hope nobody will object to patches that cleanup/delete some code ;-)
>
> -Emil
More information about the mesa-dev
mailing list