After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 349575 - fix build with gcc 2.95
fix build with gcc 2.95
Status: RESOLVED FIXED
Product: gtk-engines
Classification: Deprecated
Component: general
2.7.x
Other Linux
: Normal normal
: ---
Assigned To: gtk-engines maintainers
gtk-engines maintainers
Depends on:
Blocks:
 
 
Reported: 2006-08-01 18:42 UTC by Jens Granseuer
Modified: 2006-08-09 06:50 UTC
See Also:
GNOME target: ---
GNOME version: 2.15/2.16


Attachments
C89 fixes (35.02 KB, patch)
2006-08-01 18:43 UTC, Jens Granseuer
none Details | Review
additional patch (26.22 KB, patch)
2006-08-01 19:21 UTC, Jens Granseuer
none Details | Review
patch for 2.7.7 (3.12 KB, patch)
2006-08-08 15:57 UTC, Jens Granseuer
none Details | Review

Description Jens Granseuer 2006-08-01 18:42:38 UTC
The following patch gets rid of C99isms all across the map to allow compilation with gcc 2.95 and other C89 compilers.
Comment 1 Jens Granseuer 2006-08-01 18:43:06 UTC
Created attachment 70042 [details] [review]
C89 fixes
Comment 2 Jens Granseuer 2006-08-01 19:21:24 UTC
Created attachment 70043 [details] [review]
additional patch

Looks like I still missed a few engines...
Comment 3 Andrew Johnson 2006-08-02 11:57:45 UTC
Thanks For This. You really cleared up a question I had been asking myself recently. I hadn't realized that I was using C99'isms (most of those are my fault). I will try and remember this from now on. 

I have applied everything but the crux bit, since the crux engine is still in the midst of a rewrite by thomas, and it may be up to him to take care of that part of the patch. Also since this patch was made the industrial cairo rewrite by Ben was done, so you might find some other new problems as well.
Comment 4 Jens Granseuer 2006-08-02 17:51:55 UTC
I'll take a look at the next release to sort out what's left.
Comment 5 Jens Granseuer 2006-08-08 15:57:55 UTC
Created attachment 70495 [details] [review]
patch for 2.7.7

Here's a patch against 2.7.7 that fixes the rest of the bunch.
Comment 6 Andrew Johnson 2006-08-08 16:56:33 UTC
Thanks, commited, and closing bug. Feel free to reopen later on if something crops back up. It might be a good idea if possible and I can figure out how, too try and ensure that C89 is used even on C99 compilers, so that these things are bugs across the board.
Comment 7 Jens Granseuer 2006-08-08 17:17:04 UTC
gcc has -std=c89, but I'm not sure if that catches these issues.
Comment 8 Andrew Johnson 2006-08-08 18:38:04 UTC
Looks like -Wall -Werror -ansi -pedantic will catch these. but pedantic and werror show a problem in gtk (2.10?) headers.. so not persay usable since it will always fail to compile at all.
Comment 9 Jens Granseuer 2006-08-09 06:50:32 UTC
-Werror isn't a good idea anyway since you can't control what's installed on other machines and there might be lots of other warnings (completely unrelated even, if there's something afoot in system headers)