Closed Bug 552821 Opened 10 years ago Closed 4 years ago
Disable build warning: "string length XXX is greater than the length '509' ISO C90 compilers are required to support"
In a mozilla-central build, I get 40 instances of a warning like this: > warning: string length ‘781’ is greater than the length ‘509’ ISO C90 compilers are required to support It affects these files: /xpcom/typelib/xpidl/xpidl.c /media/liboggplay/src/liboggplay/x86/oggplay_yuv2rgb_x86.c /media/libtheora/lib/x86/mmxidct.c /media/libtheora/lib/x86/mmxstate.c /media/libtheora/lib/x86/mmxfrag.c /gfx/cairo/cairo/src/cairo-ps-surface.c /gfx/cairo/cairo/src/cairo-type1-subset.c The values (in ascending order, & excluding duplicates) are: 543 591 591 781 847 856 911 1248 1256 1875 2186 6107 10556 According to the GCC manpage, the limit is 509 in C89, but it's 4095 in C99, and compilers can & do support much larger values. Given that all but 2 of the 40 places triggering this warning are under 4095 (the 2 largest ones being in media/libtheora/lib/x86/mmxfrag.c), I think we should just disable this compile warning, with "-Wno-overlength-strings" GCC option. Unless we actually intend to fix these instances... and I'm assuming we don't (particularly since 509 is such a small limit -- we break that limit with just some simple "Usage: " help-text in xpidl.c)
10 years ago
WFM because we now compile as C99 instead of C89, as of bug 917526: https://hg.mozilla.org/mozilla-central/rev/5e4d9cc03f15
Status: NEW → RESOLVED
Closed: 4 years ago
Depends on: 917526
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.