-Wformat-nonliteral
Henry Jen
henry.jen at oracle.com
Fri Mar 28 16:27:07 UTC 2014
Workaround is to revert the bsd makefile change, this will get you a
build on Mac as before,
> --- a/make/bsd/makefiles/gcc.make Tue Mar 04 09:57:16 2014 -0500
> +++ b/make/bsd/makefiles/gcc.make Mon Mar 03 11:54:35 2014 +0100
> @@ -260,7 +260,7 @@
> WARNINGS_ARE_ERRORS += -Wno-empty-body
> endif
>
> -WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function -Wformat=2
> +WARNING_FLAGS = -Wpointer-arith -Wsign-compare -Wundef -Wunused-function -Wformat=2 -Wno-error=format-nonliteral
>
> ifeq ($(USE_CLANG),)
> # Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit
The better fix is to add attribute annotation, IMHO.
Cheers,
Henry
On 03/28/2014 07:06 AM, Jim Laskey (Oracle) wrote:
> Yes
>
> On Mar 28, 2014, at 11:05 AM, Staffan Larsen <staffan.larsen at oracle.com> wrote:
>
>> Building with clang?
>>
>> https://bugs.openjdk.java.net/browse/JDK-8037816
>> https://bugs.openjdk.java.net/browse/JDK-8019470
>>
>> /Staffan
>>
>>
>> On 28 mar 2014, at 14:28, Jim Laskey (Oracle) <james.laskey at oracle.com> wrote:
>>
>>> /Projects/jdk9-dev/hotspot/src/share/vm/utilities/debug.cpp:105:19: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
>>> vfprintf(err, format, ap);
>>> ^~~~~~
>>>
>>>
>>> Try to build jdk9-dev tip I ran into this. Wassup?
>>>
>>> -- Jim
>>>
>>
>
More information about the build-dev
mailing list