This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

egcs-2.91.60 on SGI: string.h problem



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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]