[GRASS-user] Compilation error in tonight's CVS

Tom Russo russo at bogodyn.org
Wed Jun 7 01:55:42 EDT 2006


I just tried building CVS grass after a few weeks of not updating.  I'm 
on FreeBSD 5.4.

The error is in lib/gis/error.c, a complaint about an inconsistent definition
of write_error that doesn't match the prototype in the declaration earlier.

static int write_error (const char *, const int, const char *, 
                        const int, const char *);

and later:
static int write_error (const char *msg, const int fatal,
                        const char *dir, const time_t clock,
                        const char *cwd)
{

In the definition clock is const time_t, in the declaration it's const int.
Apparently on FreeBSD they're not equivalent and the compiler chokes building
libgrass_gis.  For whatever reason, this does *not* cause the entire make to
stop dead in its tracks --- it continues to try to build everything else,
and everything else fails to link because libgrass_gis can't be found. 

Changing the declaration to have "const time_t" to match the definition
fixes the problem.

-- 
Tom Russo    KM5VY     SAR502  DM64ux         http://www.swcp.com/~russo/
Tijeras, NM  QRPL#1592 K2#398  SOC#236  SKCC#2002
"And, isn't sanity really just a one-trick pony anyway? I mean all you get is
 one trick, rational thinking, but when you're good and crazy, oooh, oooh,
 oooh, the sky is the limit!"  --- The Tick




More information about the grass-user mailing list