WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-ppc-devel

Re: [XenPPC] [xenppc-unstable] [POWERPC] Enable gcc -Wshadow and fix the

Addition of -Wshadow generates warnings when compiling powerpc64/asm-offsets.c

> diff -r 0af18fd083ed -r b10e48a5d1e3 xen/arch/powerpc/Makefile
> --- a/xen/arch/powerpc/Makefile       Fri Aug 18 05:00:37 2006 -0400
> +++ b/xen/arch/powerpc/Makefile       Fri Aug 18 05:17:14 2006 -0400
> @@ -47,6 +47,7 @@ obj-y += elf32.o
>  # These are extra warnings like for the arch/ppc directory but may not
>  # allow the rest of the tree to build.
>  PPC_C_WARNINGS += -Wundef -Wmissing-prototypes -Wmissing-declarations
> +PPC_C_WARNINGS += -Wshadow
>  CFLAGS += $(PPC_C_WARNINGS)

make -f /home/poff/xenppc-unstable-work7.hg/xen/Rules.mk -C arch/powerpc 
asm-offsets.s
make[2]: Entering directory 
`/home/poff/xenppc-unstable-work7.hg/xen/arch/powerpc'
powerpc64-unknown-linux-gnu-gcc -m64 -ffreestanding -fno-builtin -fno-common 
-fno-strict-aliasing -iwithprefix include -Wall -Werror -pipe 
-I/home/poff/xenppc-unstable-work7.hg/xen/include 
-I/home/poff/xenppc-unstable-work7.hg/xen/include/asm-powerpc/mach-generic 
-I/home/poff/xenppc-unstable-work7.hg/xen/include/asm-powerpc/mach-default 
-Wpointer-arith -Wredundant-decls -Wpacked -msoft-float -O2 -O0 -g -D__XEN__ 
-DVERBOSE -DCRASH_DEBUG -Wundef -Wmissing-prototypes -Wmissing-declarations 
-Wshadow -S -o asm-offsets.s powerpc64/asm-offsets.c
In file included from 
/home/poff/xenppc-unstable-work7.hg/xen/include/asm/smp.h:26,
                 from 
/home/poff/xenppc-unstable-work7.hg/xen/include/xen/smp.h:13,
                 from 
/home/poff/xenppc-unstable-work7.hg/xen/include/asm/spinlock.h:25,
                 from 
/home/poff/xenppc-unstable-work7.hg/xen/include/xen/spinlock.h:39,
                 from 
/home/poff/xenppc-unstable-work7.hg/xen/include/xen/sched.h:7,
                 from powerpc64/asm-offsets.c:9:
/home/poff/xenppc-unstable-work7.hg/xen/include/asm/current.h: In function 
`reset_stack_and_jump':
/home/poff/xenppc-unstable-work7.hg/xen/include/asm/current.h:69: warning: 
declaration of 'f' shadows a parameter
/home/poff/xenppc-unstable-work7.hg/xen/include/asm/current.h:67: warning: 
shadowed declaration is here
make[2]: *** [asm-offsets.s] Error 1

_______________________________________________
Xen-ppc-devel mailing list
Xen-ppc-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-ppc-devel