Need Help with g++ and/or codaLite


 
Thread Tools Search this Thread
Top Forums Programming Need Help with g++ and/or codaLite
# 1  
Old 01-04-2010
Need Help with g++ and/or codaLite

I am running a linux-x86 machine with Ubuntu 9.10. Currently we are trying to re-build the data acquisition system in my lab, and to do this we must interface the linux machine with a VME crate via codaLite.

My question pertains to the compilation error I am receiving from g++. At the top of the file cMsgRoc.cc the header file exists as

#include <string>
etc etc

the string.h file exists in /usr/include and contains the corresponding function so that I'm assuming it is up to date.

I've hit a stand-still and would really appreciate any help! Thanks in advance!





g++ -I../libsrc++ -I. -I/usr/local/codaLite/coda/include -I/usr/local/codaLite/coda/include -I/usr/local/codaLite/coda/include -I/apps/expat/include -I/usr/local/codaLite/coda/include -Wall -fPIC -D_GNU_SOURCE -m32 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -c -o .Linux-i686/objects/cMsgRoc.o cMsgRoc.cc
cMsgRoc.cc: In member function ‘void cMsgRoc::evThread()':
cMsgRoc.cc:233: warning: ‘i' may be used uninitialized in this function
g++ -L/usr/local/codaLite/coda/Linux-i686/lib -m32 .Linux-i686/objects/cMsgRoc.o -L/usr/local/codaLite/coda/Linux-i686/lib -lcmsgxx -lcmsg -lcmsgRegex -L/usr/local/codaLite/coda/Linux-i686/lib -levioxx -levio -L/apps/expat/lib -lexpat -L/usr/local/codaLite/coda/Linux-i686/lib -lcodaObject -lieee -lrt -lpthread -lz -lm -lnsl -lresolv -ldl -o .Linux-i686/bin/cMsgRoc
g++ -I../libsrc++ -I. -I/usr/local/codaLite/coda/include -I/usr/local/codaLite/coda/include -I/usr/local/codaLite/coda/include -I/apps/expat/include -I/usr/local/codaLite/coda/include -Wall -fPIC -D_GNU_SOURCE -m32 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -c -o .Linux-i686/objects/cMsgRoc2.o cMsgRoc2.cc
cMsgRoc2.cc: In function ‘void decode_command_line(int, char**)':
cMsgRoc2.cc:376: error: ‘strncasecmp' was not declared in this scope
make[1]: *** [cMsgRoc2.o] Error 1
make[1]: Leaving directory `/usr/local/codaLite/codaObject/src/execsrc'
make: *** [install] Error 2
# 2  
Old 01-04-2010
Quote:
Originally Posted by henslewm
My question pertains to the compilation error I am receiving from g++. At the top of the file cMsgRoc.cc the header file exists as

#include <string>

etc etc

the string.h file exists in /usr/include and contains the corresponding function so that I'm assuming it is up to date.
#include <string> includes something like /usr/lib/gcc/i686-pc-linux-gnu/4.1.2/include/g++-v4/string, and not /usr/include/string.h. The C++ string headers have nothing to do with the C ones. Try adding the line
Code:
#include <string.h>

Or even strings.h, as strncasecmp's manpage suggests it needs.
# 3  
Old 01-04-2010
Thanks for the fast reply, I'll give it a try.
Login or Register to Ask a Question

Previous Thread | Next Thread
Login or Register to Ask a Question