[OpenJDK 2D-Dev] JDK-8081295: Build failed with GCC 5.1.1
yasuenag at gmail.com
Thu May 28 03:19:45 UTC 2015
I tried to build jdk9/dev on Fedora22 with GCC 5.1.1, however, it was failed.
I found several problems:
Fedora release 22 (Twenty Two) x86_64
1. Array bounds check in GCC
It seems to be bug of GCC:
Bug 59124: [4.8/4.9/5/6 Regression] Wrong warnings "array subscript is above array bounds"
I think implementations of these files have no problem.
So I propose to ignore warning(s) of compiler through pragma option as
workaround when we use GCC .
2. Local variables might be clobbered
SplashDecodePng() calls setjmp(3).
Some local variables initialize before setjmp() call, and use after it.
Their initial values are only used at cleanup code (*done* label) and
actual values are stored only after setjmp() call.
So I think we can ignore this error through pragma option .
3. Incorrect condition
searchAllSourceNames() returns int value. However, branch condition in
eventFilterRestricted_passesFilter() treats it as boolean value.
I received a comment from Erik to use --disable-warnings-as-errors,
however I could not avoid error in 3.
More information about the 2d-dev