This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
egcs-2.91.60 on SGI: string.h problem
- To: help-gcc at gnu dot org
- Subject: egcs-2.91.60 on SGI: string.h problem
- From: dolan at uwast dot astro dot wisc dot edu (Chris Dolan)
- Date: 24 Nov 1999 22:14:57 GMT
- Newsgroups: gnu.gcc.help
- Organization: University of Wisconsin - Astronomy Department
- Xref: wodc7nx0 gnu.gcc.help:1959
Let me apologize in advance for this question! I've already found an
easy workaround for my problem. I'd just like to know the *right*
answer.
I'm using GNU c++ (egcs-2.91.60 -- sorry, I don't have access to the
latest version) on an SGI IRIX 6.5 system. It seems that c++ reads
SGI's /usr/include/string.h file when I #include <string.h>. The
problem is that (due to some #ifdefs I think) c++ doesn't get some of
the prototypes. For example it never gets char *strstr(...) so it
guesses it as int strstr() which causes compile errors when I compare
to a pointer.
First, is this a known/fixed problem? I searched the Cygnus, GNU and
SGI web pages to no avail.
Otherwise, is there an easy way to make the GNU compiler automatically
use the GNU include file (/usr/local/lib/g++-include/string.h in my
case). I realize I could put that directory in the search path with
-I, but I'm hoping there might be a cleaner solution, that doesn't
require me to modify any Makefiles or source code.
I would be grateful for an email reply to dolan@astro.wisc.edu if that
is convenient.
Thanks in advance!
Chris Dolan