On Wed, Aug 24, 2005 at 08:31:04PM -0400, Dan Espen wrote:
> Mikhael Goikhman <[EMAIL PROTECTED]> writes:
> > On 24 Aug 2005 23:30:41 +0200, Dominik Vogt wrote:
> > > 
> > > I never commit code that issues warnings.  What do you get?
> > 
> > You should try gcc 4.x, there are zillions of warnings (or more). :)
> > Most of them are innocent, I believe, but I didn't really had a time to
> > learn about new strict gcc rules yet.
> 
> I've been getting these:
> 
> gcc -DHAVE_CONFIG_H -I. -I../../fvwm2_5_13/fvwm -I.. -I../../fvwm2_5_13 
> -I../../fvwm2_5_13/libs  -I/usr/X11R6/include -I/usr/local/include 
> -I/usr/local/include/freetype2 -I/usr/local/include/freetype2/config 
> -I/usr/X11R6/include -I/usr/X11R6/include      -I/usr/X11R6/include           
>      -DFVWM_MODULEDIR=\"/home/dane/bin/fvwm/exec/fvwm/2.5.14\"  
> -DFVWM_DATADIR=\"/home/dane/bin/fvwm/share/2.5.13/fvwm\"        
> -DFVWM_CONFDIR=\"/home/dane/bin/fvwm/etc/2.5.13\"       
> -DFVWM_COLORSET_PRIVATE=1       
> -DLOCALEDIR=\"/home/dane/bin/fvwm/share/2.5.13/locale\" -Wall 
> -Wno-implicit-int -g -O2 -c ../../fvwm2_5_13/fvwm/menus.c
> ../../fvwm2_5_13/fvwm/menus.c: In function `find_entry':
> ../../fvwm2_5_13/fvwm/menus.c:555: warning: dereferencing type-punned pointer 
> will break strict-aliasing rules
> ../../fvwm2_5_13/fvwm/menus.c: In function `menu_enter_tear_off_menu':
> ../../fvwm2_5_13/fvwm/menus.c:6155: warning: dereferencing type-punned 
> pointer will break strict-aliasing rules
> ../../fvwm2_5_13/fvwm/menus.c: In function `menu_close_tear_off_menu':

Add "-fno-stric-aliasing" to the CFLAGS.  The DEVELOPERS file asks
to compile with 

  make CFLAGS="-g -O2 -Wall -Wpointer-arith -fno-stric-aliasing -Werror"

to get eid of useless warnings.

> home> gcc -v
> Reading specs from /new/local/bin/../lib/gcc/i686-pc-linux-gnu/3.4.3/specs
> Configured with: ../configure 
> Thread model: posix
> gcc version 3.4.3

Ciao

Dominik ^_^  ^_^

 --
Dominik Vogt, [EMAIL PROTECTED]

Attachment: signature.asc
Description: Digital signature

Reply via email to