[GRASS5] configuration/build failure on solaris 8, curses and get/putwc

Glynn Clements glynn.clements at virgin.net
Tue Jun 18 14:02:43 EDT 2002


Hal Mueller wrote:

> The subject line refers to the cause of the problem, not just my 
> reaction to it.  I believe the problem is nested includes from 
> "curses" redefining getwc/putwc.  This is on Solaris 8 (Sparc) with 
> gcc 2.8.  My results reported are from the current CVS build, but my 
> results with pre4 were similar.
> 
> "configure" with the current release tree, and with pre4, fails with 
> the following error:
> 
> checking for remove... yes
> checking for shmat... yes
> checking for IceConnectionNumber in -lICE... yes
> checking for curses.h... no
> configure: error: *** Unable to locate curses includes.
> 
> However, I think the problem surfaces higher up, where "configure" reports
> 
> checking how to run the C preprocessor... gcc -E
> checking for ANSI C header files... yes
> checking for curses.h... no
> checking for limits.h... yes
> 
> The log file segment for the initial curses.h check looks like this:
> 
> configure:2319: checking for curses.h
> configure:2327: gcc -E  conftest.c >/dev/null 2>conftest.out
> In file included from /usr/include/curses.h:23,
>                   from 
> /usr/local/lib/gcc-lib/sparc-sun-solaris2.8/2.95.2/include
> /curses.h:5,
>                   from configure:2323:
> /usr/include/widec.h:38: warning: `getwc' redefined
> /usr/include/iso/wchar_iso.h:337: warning: this is the location of the previous
> definition
> /usr/include/widec.h:39: warning: `putwc' redefined
> /usr/include/iso/wchar_iso.h:340: warning: this is the location of the previous
> definition
> /usr/include/widec.h:40: warning: `getwchar' redefined
> /usr/include/iso/wchar_iso.h:338: warning: this is the location of the previous
> definition
> /usr/include/widec.h:41: warning: `putwchar' redefined
> /usr/include/iso/wchar_iso.h:341: warning: this is the location of the previous
> definition
> configure: failed program was:
> #line 2322 "configure"
> #include "confdefs.h"
> #include <curses.h>
> configure:2319: checking for limits.h

Two comments.

1. autoconf's AC_TRY_CPP macro (used by AC_CHECK_HEADERS) fails if the
preprocessor writes anything to stderr, even if they are only
warnings. You could try 'CPPFLAGS=-w ./configure ...'.

2. Ultimately the problem is with the development environment. Have
you tried (re)running gcc's "fixincludes" script? If that fails, my
only suggestion is to modify curses.h so that it can be included
without generating any warnings. I would assume that any configure
script will have the same problems.

-- 
Glynn Clements <glynn.clements at virgin.net>



More information about the grass-dev mailing list