Problem with "configure checks for gcc options that clang does not support"

Lubos Lunak l.lunak at suse.cz
Tue Apr 24 02:01:01 PDT 2012


On Monday 23 of April 2012, Tor Lillqvist wrote:
> Unfortunately, at least the Apple Clang doesn't generate any
> compilation error or *proper* warning for command-line options it
> doesn't understand, like -fno-enforce-eh-specs.
>
> It just prints out clang: warning: argument unused during compilation:
> '-fno-enforce-eh-specs' to stderr... Even with -Werror, this is just
> printed, it doesn't cause the compilation to exit with failure.

 That's a wee bit broken. And not just with my commit, but in general, there 
are other configure checks that test whether an option is supported or not, 
just grep configure.in for -Werror.

> So probably configure should check if this warning is printed to
> stderr when checking what command-line options are supported?

 That does not quite work, e.g. the message can be translated.

 But the bug seems to exists only with Clang < 3.1, so the problem can be 
worked around by checking for such versions and overriding all results of 
such checks to values manually found out.

-- 
 Lubos Lunak
 l.lunak at suse.cz


More information about the LibreOffice mailing list