Bug 43191 - [Qt] Treat warnings as errors by default for gcc
Summary: [Qt] Treat warnings as errors by default for gcc
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P3 Normal
Assignee: Nobody
URL:
Keywords: Qt, QtTriaged
: 37916 (view as bug list)
Depends on: 20721 37916 38045 43192 43193 43350 43353 43355 43356 43358 43359 43360 43412 43413 43698 43876 43920 43963 44466 44468 44593 44672 44843 44855 45246 45301 45373 45384 67778 67928 83584
Blocks:
  Show dependency treegraph
 
Reported: 2010-07-29 08:39 PDT by Csaba Osztrogonác
Modified: 2013-11-22 08:54 PST (History)
8 users (show)

See Also:


Attachments
enable -Werror on x86/Linux/GCC platforms (1.20 KB, patch)
2010-09-08 01:55 PDT, Csaba Osztrogonác
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Csaba Osztrogonác 2010-07-29 08:39:34 PDT
I create this bug because of discussion in https://bugs.webkit.org/show_bug.cgi?id=30958 .

I agree with Laszlo, we should treat warnings as errors 
to avoid breaking other platforms accidentally.

The main goal of this patch is adding -Werror to QMAKE_CFLAGS,
but it depends on fixing dozens of warning. First we can focus
on x86-linux and x86-windows platforms and then ARM-linux and 
other platforms.
Comment 1 Csaba Osztrogonác 2010-07-29 08:42:40 PDT
(In reply to comment #9 in https://bugs.webkit.org/show_bug.cgi?id=30958)
> My only concern would be the extra pressure to fix these warnings to keep the bot green. CCing Ossy to see what he think.
 
> A somewhat relaxed version of this - which I think we should do - is to start treating warnings as errors by default (at least on platforms where this is realistic like i386) but have a provision (e.g. environment variable) not to do this for the build bot.
 
> This will force most developers to look into the warning but does not put extra pressure on the bot.

I absolutely agree with Laszlo, it is a good way to solve this bug.
Comment 2 Csaba Osztrogonác 2010-08-02 10:05:29 PDT
*** Bug 37916 has been marked as a duplicate of this bug. ***
Comment 3 Csaba Osztrogonác 2010-09-08 01:55:33 PDT
Created attachment 66858 [details]
enable -Werror on x86/Linux/GCC platforms

I think it's time to enable -Werror on x86/Linux/GCC platforms
after https://bugs.webkit.org/show_bug.cgi?id=45373 fixed.

The next steps will be Windows/GCC and ARM/Linux/GCC after all warnings fixed.
Comment 4 Andreas Kling 2010-09-08 03:35:29 PDT
Comment on attachment 66858 [details]
enable -Werror on x86/Linux/GCC platforms

r=me

I always feel silly when the EWS slaps me about some warning that my own machine knew about but wasn't loud enough.
Comment 5 Csaba Osztrogonác 2010-09-08 03:38:25 PDT
Comment on attachment 66858 [details]
enable -Werror on x86/Linux/GCC platforms

cq-, because I will land manually after 
https://bugs.webkit.org/show_bug.cgi?id=45373 fixed
Comment 6 Csaba Osztrogonác 2010-09-08 04:35:11 PDT
Comment on attachment 66858 [details]
enable -Werror on x86/Linux/GCC platforms

Clearing flags on attachment: 66858

Committed r66972: <http://trac.webkit.org/changeset/66972>
Comment 7 Csaba Osztrogonác 2010-09-08 09:54:19 PDT
(In reply to comment #6)
> (From update of attachment 66858 [details])
> Clearing flags on attachment: 66858
> 
> Committed r66972: <http://trac.webkit.org/changeset/66972>
And a buildfix landed in http://trac.webkit.org/changeset/66990 ,
because linux-g++ is true when you build for maemo inside sbox,
but we didn't want to enable -Werror for it now.

I didn't run into this issue, because linux-g++ is false 
for ARM cross compiling, but linux-arm-g++ is true.
Comment 8 Laszlo Gombos 2010-09-08 14:49:24 PDT
Very nice, thanks for all this work !