https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68610
Bug ID: 68610
Summary: configure failure in libssp
Product: gcc
Version: 6.0
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: other
Assignee: unassigned at gcc dot gnu.org
Reporter: gccbugzilla at limegreensocks dot com
Target Milestone: ---
I was trying to figure out why I was getting this warning from ssp.c in libssp
when building gcc on i386:
warning: visibility attribute not supported in this configuration; ignored
Configure checks to see if this attribute is supported and sets a #define, so I
was puzzled why that wasn't working. After looking thru the configure script,
it appears that the configure check is failing because compiling the test code
throws a 'warning' instead of an error:
conftest.c:12:1: warning: visibility attribute not supported in this
configuration; ignored [-Wattributes]
And the reason it does seems to be that ac_c_werror_flag is assumed to contain
the switch to turn the warning into an error (-Werror), when in fact it is
undefined. Setting this to -Werror causes the configure check to correctly
detect that visibility isn't supported, and the warning from ssp.c disappears.
A lot of gcc's configure scripts use ac_c_werror_flag, but I'm not sure it ever
gets set to -Werror. Sometimes it gets set to "yes", but that can't be right.