[GRASS5] Re: 5.0.3 release candidate 1

Markus Neteler neteler at itc.it
Mon Sep 8 08:00:18 EDT 2003


On Thu, Sep 04, 2003 at 11:04:07PM +0100, Glynn Clements wrote:
> 
> Markus Neteler wrote:
> 
> > > > > ps -- can anything be done to get rid of all the 
> > > > > src/include/gis.h:35: warning: `GRASS_copyright' defined but not used
> > > > > warnings?
> > > 
> > > For gcc, use the "unused" attribute:
> > > 
> > > 	#ifndef __GNUC__
> > > 	#define __attribute__(x)
> > > 	#endif
> > > 	
> > > 	...
> > > 	
> > > 	static const char *GRASS_copyright = "GRASS GNU GPL licensed Software"
> > > 		__attribute__((unused)) ;
> > 
> > Will you apply this to CVS?
> 
> Committed to HEAD; given that this merely suppresses warnings, I'm not
> sure that it should go into the release branch yet (breaking gis.h
> would break absolutely everything).
> 
> For good measure, I've also added:
> 
> 	__attribute__((format(printf,1,2)))
> 
> to the declarations of G_fatal_error() and G_warning() in gisdefs.h,
> so gcc will detect if the arguments don't match the specifiers in the
> format string.

The same I have applied to 5.1 now.

Markus




More information about the grass-dev mailing list