[OpenBIOS] [PATCH 1/3] SPARC64: fix build warnings on gcc6

Cole Robinson crobinso at redhat.com
Tue Mar 15 19:19:22 CET 2016


On 03/12/2016 06:25 AM, Mark Cave-Ayland wrote:
> On 11/03/16 19:05, Cole Robinson wrote:
> 
>> After these patches there's still an extra warning (besides the string.h bit):
>>
>> In file included from /builddir/build/BUILD/openbios-1.1/drivers/obio.c:14:0:
>> /builddir/build/BUILD/openbios-1.1/drivers/obio.c:30:23: warning:
>> 'ob_obio_size_' defined but not used [-Wunused-const-variable]
>>  DECLARE_UNNAMED_NODE( ob_obio, INSTALL_OPEN, sizeof(int) );
>>                        ^
>> /builddir/build/BUILD/openbios-1.1/include/libopenbios/bindings.h:132:18:
>> note: in definition of macro 'DECLARE_UNNAMED_NODE'
>>  static const int name##_size_ = size;
>>                   ^~~~
>> /builddir/build/BUILD/openbios-1.1/drivers/obio.c:30:23: warning:
>> 'ob_obio_flags_' defined but not used [-Wunused-const-variable]
>>  DECLARE_UNNAMED_NODE( ob_obio, INSTALL_OPEN, sizeof(int) );
>>                        ^
>> /builddir/build/BUILD/openbios-1.1/include/libopenbios/bindings.h:131:18:
>> note: in definition of macro 'DECLARE_UNNAMED_NODE'
>>  static const int name##_flags_ = flags; \
>>
>> - Cole
> 
> Looks like I missed removing the final DECLARE_UNNAMED_NODE define at
> the top of the file - this should be fixed by the v2 sent out.
> 

Tested, it works. Thanks!

> The fact that the string.h warning is only present for the PPC build
> makes me suspicious that this is a compiler bug. With the v2 patchset
> applied, is that enough for you to get one of the Fedora compiler guys
> to take a quick look at this?
> 

Actually I think it _is_ the fixed gcc issue pointed out earlier... I forgot
that in fedora, the cross gcc builds are packaged separately from the main gcc
package. The main fedora gcc package has the fix backported, but the cross-gcc
doesn't have it yet.

- Cole



More information about the OpenBIOS mailing list