Project Home
Project Home
Trackers
Trackers
Documents
Documents
Wiki
Wiki
Discussion Forums
Discussions
Project Information
Project Info
Forum Topic - Intel QNX Compiler 11.0.X with gcc 3.3.5 (own makefile): (3 Items)
   
Intel QNX Compiler 11.0.X with gcc 3.3.5 (own makefile)  
Hello,

I try to get the Intel Compiler running with QNX Momentics 6.3.0SP3.
We use our own Makefile.

Does anyone has any experience in that issue?

It seems that the icc does not found the standard c++ libraries when linking.

----------------------------

We use following commands. (with the old compiler we haved used -cxxlib-icc, but this is removed)


DEBUG_CL= icpc  -w -g -debug extended -static -L $(LIB_DIR) -L $(DEBUG_GLOBAL_LIB_DIR) -L $(DEBUG_LIB_DIR) -D$
(TARGET_OS)

DEBUG_CC= icpc -w -g -debug extended -lstd -I $(INCLUDE_DIR) -I $(GLOBAL_INCLUDE_DIR) -I $(EXTERN_INCLUDE_DIR) -D$
(TARGET_OS) -DNDEBUG


----------------------------

Following errors do we have:

icpc  -w -g -debug extended -static -L M:\User\iwe\QNX\debug\lib -L M:\Global\QNX\debug\lib -L M:\User\iwe\QNX\debug\lib
 -D_NTO_ -o M:\User\iwe\QNX\debug\bin\DriverTest M:\User\iwe\QNX\debug\obj\DriverTest.o M:\User\iwe\QNX\debug\obj\
TestLib.o -limf -lcprts -lsvml -lirc -lunwind -lcxa 
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale.o): In function `std::locale::global(std::locale const&)':
locale.o(.text._ZNSt6locale6globalERKS_+0x64): undefined reference to `strcmp'
locale.o(.text._ZNSt6locale6globalERKS_+0xd9): undefined reference to `setlocale'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale.o): In function `std::locale::name() const':
locale.o(.text._ZNKSt6locale4nameEv+0x59): undefined reference to `strcmp'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `std::__timepunct<char>:
:__timepunct(int*, char const*, unsigned)':
locale-inst.o(.gnu.linkonce.t._ZNSt11__timepunctIcEC2EPiPKcj+0x3e): undefined reference to `strcpy'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `std::__timepunct<char>::__timepunct(int
*, char const*, unsigned)':
locale-inst.o(.gnu.linkonce.t._ZNSt11__timepunctIcEC1EPiPKcj+0x3e): undefined reference to `strcpy'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int std::__convert_from_v<double>(char*
, int, char const*, double, int* const&, int)':
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x17): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x42): undefined reference to `strcpy'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x54): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x70): undefined reference to `sprintf'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x80): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0xa5): undefined reference to `sprintf'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int std::__convert_from_v<long double>(char*, int, char const*, long double, int* const&, int)':
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x11): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x3c): undefined reference to `strcpy'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x4e): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x6d): undefined reference to `sprintf'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x7a): undefined reference to `setlocale'
C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int std::__convert_from_v<long>(char*, int, 
char const*, long, int* const&, int)':
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIlEiPciPKcT_RKPii+0x11): undefined reference to `setlocale'
locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIlEiPciPKcT_RKPii+0x3c): undefined reference to...
View Full Message
Re: Intel QNX Compiler 11.0.X with gcc 3.3.5 (own makefile)  
I think libc is not linked in. Does you compiler (linker) adds this automatically?

Ingo Weidauer wrote:
> Hello,
> 
> I try to get the Intel Compiler running with QNX Momentics 6.3.0SP3.
> We use our own Makefile.
> 
> Does anyone has any experience in that issue?
> 
> It seems that the icc does not found the standard c++ libraries when linking.
> 
> ----------------------------
> 
> We use following commands. (with the old compiler we haved used -cxxlib-icc, but this is removed)
> 
> 
> DEBUG_CL= icpc  -w -g -debug extended -static -L $(LIB_DIR) -L $(DEBUG_GLOBAL_LIB_DIR) -L $(DEBUG_LIB_DIR) -D$
(TARGET_OS)
> 
> DEBUG_CC= icpc -w -g -debug extended -lstd -I $(INCLUDE_DIR) -I $(GLOBAL_INCLUDE_DIR) -I $(EXTERN_INCLUDE_DIR) -D$
(TARGET_OS) -DNDEBUG
> 
> 
> ----------------------------
> 
> Following errors do we have:
> 
> icpc  -w -g -debug extended -static -L M:\User\iwe\QNX\debug\lib -L M:\Global\QNX\debug\lib -L M:\User\iwe\QNX\debug\
lib -D_NTO_ -o M:\User\iwe\QNX\debug\bin\DriverTest M:\User\iwe\QNX\debug\obj\DriverTest.o M:\User\iwe\QNX\debug\obj\
TestLib.o -limf -lcprts -lsvml -lirc -lunwind -lcxa 
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale.o): In function `std::locale::global(std::locale const&)':
> 
locale.o(.text._ZNSt6locale6globalERKS_+0x64): undefined reference to `strcmp'
> locale.o(.text._ZNSt6locale6globalERKS_+0xd9): undefined reference to `setlocale'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale.o): In function `std::locale::name() const':
> locale.o(.text._ZNKSt6locale4nameEv+0x59): undefined reference to `strcmp'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `std::__timepunct<char>::
__timepunct(int*, char const*, unsigned)':
> locale-inst.o(.gnu.linkonce.t._ZNSt11__timepunctIcEC2EPiPKcj+0x3e): undefined reference to `strcpy'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `std::__timepunct<char>::
__timepunct(int*, char const*, unsigned)':
> locale-inst.o(.gnu.linkonce.t._ZNSt11__timepunctIcEC1EPiPKcj+0x3e): undefined reference to `strcpy'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int std::__convert_from_v<double>
(char*, int, char const*, double, int* const&, int)':
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+
0x17): undefined reference to `setlocale'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x42): undefined reference to `strcpy'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x54): undefined reference to `setlocale'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x70): undefined reference to `sprintf'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0x80): undefined reference to `setlocale'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIdEiPciPKcT_RKPii+0xa5): undefined reference to `sprintf'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int std::__convert_from_v<long double
>(char*, int, char const*, long double, int* const&, int)':
> locale-inst.o(.gnu.linkonce.t.
_ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x11): undefined reference to `setlocale'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x3c): undefined reference to `strcpy'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x4e): undefined reference to `setlocale'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x6d): undefined reference to `sprintf'
> locale-inst.o(.gnu.linkonce.t._ZSt16__convert_from_vIeEiPciPKcT_RKPii+0x7a): undefined reference to `setlocale'
> C:/QNX630/target/qnx6/x86/lib/gcc/3.3.5/libstdc++.a(locale-inst.o): In function `int...
View Full Message
Re: Intel QNX Compiler 11.0.X with gcc 3.3.5 (own makefile)  
I suppose not.

I used the following command, with the same result. 

icpc  -w -g -debug extended -libc -lstdc++ -lstd -static -L M:\User\iwe\QNX\debug\lib -L M:\Global\QNX\debug\lib -L M:\
User\iwe\QNX\debug\lib -D_NTO_ -limf -lcprts -lsvml -lirc -lunwind -lcxa -o M:\User\iwe\QNX\debug\bin\DriverTest M:\User
\iwe\QNX\debug\obj\DriverTest.o M:\User\iwe\QNX\debug\obj\TestLib.o -lphantom 

what is the correct parameter for libc. "-libc"?