Bug 233655 - Enable "comparison with string literal" gcc warnings?
Summary: Enable "comparison with string literal" gcc warnings?
Status: RESOLVED FIXED
: 224662 225435 225904 228222 228963 229369 229785 231180 231181 233016 233328 235553 (view as bug list)
Alias: None
Product: openSUSE 10.3
Classification: openSUSE
Component: Other (show other bugs)
Version: unspecified
Hardware: Other Other
: P5 - None : Normal (vote)
Target Milestone: ---
Assignee: Marcus Meissner
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-01-11 15:55 UTC by Stefan Dirsch
Modified: 2008-07-09 06:34 UTC (History)
4 users (show)

See Also:
Found By: Other
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Dirsch 2007-01-11 15:55:44 UTC
I wonder whether we should we enable "comparison with string literal" gcc warnings (RPM_OPT_FLAGS) and even trigger a fatal build error? I think we could safe David's resources (rebuilding each package and filing bugreports) and Novell's resources (bugreport handling) as well.
Comment 1 Stefan Dirsch 2007-01-11 15:56:09 UTC
*** Bug 233328 has been marked as a duplicate of this bug. ***
Comment 2 Marcus Meissner 2007-01-11 16:01:55 UTC
-Wstring-literal-comparison

is introduced with gcc4.2, which we do not use yet in abuild.

as soon as we switch to it, we can of course enable it.
Comment 3 Dirk Mueller 2007-01-11 16:23:58 UTC
unfortunately it was so far not possible to test 4.2 in BETA, so this might take a while. 

Comment 4 David Binderman 2007-01-11 19:46:00 UTC
(In reply to comment #0)
> I wonder whether we should we enable "comparison with string literal" gcc
> warnings (RPM_OPT_FLAGS) and even trigger a fatal build error? I think we could
> safe David's resources (rebuilding each package and filing bugreports) and
> Novell's resources (bugreport handling) as well.

Fame at last ;->

I've got plenty of spare time.

Also, only about 90% of the warnings are worth fixing, so I wouldn't
recommend making it a fatal error, because of the about 10% where it
doesn't seem to be a problem.
Comment 5 Matej Horvath 2007-01-17 09:57:05 UTC
*** Bug 235553 has been marked as a duplicate of this bug. ***
Comment 6 Marcus Meissner 2007-01-17 17:08:22 UTC
These are now enabled and working in BETA (which has gcc4.2) and will
also be active in Factory once the new GCC is put there.
Comment 7 Dirk Mueller 2007-01-18 13:57:38 UTC
*** Bug 229369 has been marked as a duplicate of this bug. ***
Comment 8 Joe Hargadon 2007-01-18 16:54:31 UTC
*** Bug 231180 has been marked as a duplicate of this bug. ***
Comment 9 Joe Hargadon 2007-01-18 16:55:02 UTC
*** Bug 225904 has been marked as a duplicate of this bug. ***
Comment 10 David Binderman 2007-01-19 22:58:48 UTC
(In reply to comment #0)
> I wonder whether we should we enable "comparison with string literal" gcc
> warnings (RPM_OPT_FLAGS) and even trigger a fatal build error? 

I suspect that you could do very similar things for the 
"x is used uninitialized" gcc warning message.

I can't think of any scenario where you would want to read from
a local variable that the gcc compiler is sure contains rubbish.
Comment 11 Stefan Dirsch 2007-01-20 04:40:32 UTC
I suggest to open another bugreport for this request.
Comment 12 Marcus Meissner 2007-01-20 07:21:01 UTC
we already warn for those. I have so-far post poned making those hard errors, since last time we had discussions because they triggered too often.
Comment 13 Petr Gajdos 2007-03-08 14:46:40 UTC
*** Bug 233016 has been marked as a duplicate of this bug. ***
Comment 14 Petr Gajdos 2007-03-08 14:48:08 UTC
*** Bug 228963 has been marked as a duplicate of this bug. ***
Comment 15 Petr Gajdos 2007-04-18 12:06:53 UTC
*** Bug 231181 has been marked as a duplicate of this bug. ***
Comment 16 Hendrik Vogelsang 2007-07-03 15:14:03 UTC
*** Bug 224662 has been marked as a duplicate of this bug. ***
Comment 17 Hendrik Vogelsang 2007-07-03 15:14:23 UTC
*** Bug 228222 has been marked as a duplicate of this bug. ***
Comment 18 Hendrik Vogelsang 2007-07-03 15:14:35 UTC
*** Bug 229785 has been marked as a duplicate of this bug. ***
Comment 19 Adrian Schröter 2008-07-09 06:34:11 UTC
*** Bug 225435 has been marked as a duplicate of this bug. ***