Forum Topic - QNX application crash when built with cmake (libcpp):
   
QNX application crash when built with cmake (libcpp)  
Hi, 

I compiled a simple hello word program. If I link libcpp.a the program fail as follows..

(note: I am using cmake and this toolchain file on Linux host https://github.com/aashish24/ves/blob/master/CMake/
toolchains/qnx.6.5.0.toolchain.cmake)

Any clue?


(gdb) run
Starting program: /tmp/test_dataport 
(no debugging symbols found)
[New pid 2146351 tid 1]
terminate called after throwing an instance of 'std::ios_base::failure'
  what():  

Program received signal SIGABRT, Aborted.
0xb033e0c1 in SignalKill () from /usr/qnx650/target/qnx6/x86/lib/libc.so.3
(gdb) bt
#0  0xb033e0c1 in SignalKill () from /usr/qnx650/target/qnx6/x86/lib/libc.so.3
#1  0xb032ccee in raise () from /usr/qnx650/target/qnx6/x86/lib/libc.so.3
#2  0xb032afe8 in abort () from /usr/qnx650/target/qnx6/x86/lib/libc.so.3
#3  0xb82ba8bf in __gnu_cxx::__verbose_terminate_handler () at ../../../../../libstdc++-v3/libsupc++/vterminate.cc:93
#4  0xb82b83d6 in __cxxabiv1::__terminate (handler=0xb82ba7c0 <__gnu_cxx::__verbose_terminate_handler()>) at ../../../..
/../libstdc++-v3/libsupc++/eh_terminate.cc:38
#5  0xb82b8421 in std::terminate () at ../../../../../libstdc++-v3/libsupc++/eh_terminate.cc:48
#6  0xb82b8563 in __cxa_throw (obj=0x805b0a0, tinfo=0x8054a54, dest=0xb8256000 <~failure>) at ../../../../../libstdc++-
v3/libsupc++/eh_throw.cc:83
#7  0xb8254d63 in std::__throw_ios_failure (__s=0xb82c60d1 "basic_ios::clear") at ../../../../../libstdc++-v3/src/
functexcept.cc:96
#8  0xb826c694 in std::basic_ios<char, std::char_traits<char> >::clear (this=0x8057a04, __state=2956189889)
    at /home/builder/hudson/650-gcc-4.4/svn/linux-x86-o-ntox86/i486-pc-nto-qnx6.5.0/pic/libstdc++-v3/include/bits/
basic_ios.tcc:47
#9  0xb828ab9d in sentry (this=0x8047ae8, __os=@0x8057a00)
    at /home/builder/hudson/650-gcc-4.4/svn/linux-x86-o-ntox86/i486-pc-nto-qnx6.5.0/pic/libstdc++-v3/include/bits/
basic_ios.h:148
#10 0xb828e2b5 in std::__ostream_insert<char, std::char_traits<char> > (__out=@0x8057a00, __s=0x8054260 "Welcome to the 
QNX Momentics IDE", __n=32)
    at /home/builder/hudson/650-gcc-4.4/svn/linux-x86-o-ntox86/i486-pc-nto-qnx6.5.0/pic/libstdc++-v3/include/bits/
ostream_insert.h:80
#11 0xb828e713 in operator<< <std::char_traits<char> > (__out=@0x8057a00, __s=0x8054260 "Welcome to the QNX Momentics 
IDE")
    at /home/builder/hudson/650-gcc-4.4/svn/linux-x86-o-ntox86/i486-pc-nto-qnx6.5.0/pic/libstdc++-v3/include/ostream:510

#12 0x0804b19d in main ()