[OpenBIOS] build warnings on gcc6

Cole Robinson crobinso at redhat.com
Wed Mar 9 18:46:23 CET 2016


On 03/06/2016 12:10 PM, Mark Cave-Ayland wrote:
> On 05/03/16 22:33, Cole Robinson wrote:
> 
>> openbios has some warnings (that are errors with -Werror) on gcc6. See results
>> below, with gcc6 from fedora, and building openbios revision 1378
>>
>> Thanks,
>> Cole
>>
>>
>> /builddir/build/BUILD/openbios-1.1/libc/string.c: In function 'strdup':
>> /builddir/build/BUILD/openbios-1.1/libc/string.c:353:4: warning: nonnull
>> argument 'str' compared to NULL [-Wnonnull-compare]
>>   if( !str )
>>
>>
>> In file included from /builddir/build/BUILD/openbios-1.1/drivers/sbus.c:14:0:
>> /builddir/build/BUILD/openbios-1.1/drivers/sbus.c:391:14: warning:
>> 'ob_sbus_node_m' defined but not used [-Wunused-const-variable]
>>  NODE_METHODS(ob_sbus_node) = {
>>               ^
>> /builddir/build/BUILD/openbios-1.1/include/libopenbios/bindings.h:139:23:
>> note: in definition of macro 'NODE_METHODS'
>>  static const method_t name##_m[]
>>
>>
>> In file included from /builddir/build/BUILD/openbios-1.1/arch/sparc64/lib.c:12:0:
>> /builddir/build/BUILD/openbios-1.1/arch/sparc64/lib.c:444:14: warning: 'mmu_p'
>> defined but not used [-Wunused-const-variable]
>>  DECLARE_NODE(mmu, INSTALL_OPEN, 0, "/virtual-memory");
>>               ^
>> /builddir/build/BUILD/openbios-1.1/include/libopenbios/bindings.h:135:27:
>> note: in definition of macro 'DECLARE_NODE'
>>  static const char * const name##_p[] = { paths }; \
>>                            ^~~~
>> /builddir/build/BUILD/openbios-1.1/arch/sparc64/lib.c:436:14: warning:
>> 'memory_p' defined but not used [-Wunused-const-variable]
>>  DECLARE_NODE(memory, INSTALL_OPEN, 0, "/memory");
>>               ^
>> /builddir/build/BUILD/openbios-1.1/include/libopenbios/bindings.h:135:27:
>> note: in definition of macro 'DECLARE_NODE'
>>  static const char * const name##_p[] = { paths }; \
> 
> Apart from the -Wnonnull-compare warning in strdup (which I can only
> assume figures that const char * pointers are non-null), these warnings
> do appear to be valid.
> 
> Sadly I don't have gcc6 around yet (I only install released compiler
> packages here) but I think I can fix these up. Do you have the complete
> out for sparc32, sparc64 and ppc binaries so I can also look at these or
> is it just the sparc64 build that fails?

Attached the full build output, with -Wno-error. There's some rpm build gunk
in there but it's straightforward

Thanks,
Cole

-------------- next part --------------
A non-text attachment was scrubbed...
Name: build.log
Type: text/x-log
Size: 204078 bytes
Desc: not available
URL: <http://www.coreboot.org/pipermail/openbios/attachments/20160309/12849a70/attachment-0001.log>


More information about the OpenBIOS mailing list