[Rev 01] RFR: 8241476: Linux build warning issued on updated compilers (Ubuntu 18.04.4 / 20.04)
Johan Vos
jvos at openjdk.java.net
Thu Mar 26 08:35:37 UTC 2020
On Wed, 25 Mar 2020 00:40:01 GMT, Thiago Milczarek Sayao <tsayao at openjdk.org> wrote:
>> The problem is that gcc, for whatever reason, started issuing a (useless) warning if you pass the
>> `-Werror=implicit-function-declaration` option to gcc for C++ files. I don't like the solution of removing that flag
>> for C files. I think the better solution will be to have a set of options that are common to both C and C++ (all but
>> this one currently), and then add `-Werror=implicit-function-declaration` only to the options for C. Until then, I
>> think we live with this warning. It's better than losing the checking for C files.
>
> Like this?
>
> I think all C builds are covered. Gstreamer seems to have a Makefile with the flags. Not sure about libxml and libxlst
> inside javafx.web.
I think it's better to split the flags between CFLAGS and CPPFLAGS (as is done in OpenJDK). The
`-Werror=implicit-function-declaration` is extremely useful for C files, and we don't want to risk that this somehow
got lost. If we use CFLAGS and CPPFLAGS, we can pass the latter as CXXFLAGS to cmake, so that should be fairly easy.
-------------
PR: https://git.openjdk.java.net/jfx/pull/150
More information about the openjfx-dev
mailing list