std::termiante() undefined reference.

Hi,
I’m trying to build an application using MHDDK to develop drivers for
PCI-6025E NI board.
I’m using the makefile pasted below.
When I build the projet I have these errors that I can’t resolve.

make -k EXTRA_SUFFIXES=cpp all --file=U:/PFE/PCIDrivers/QMakefile9347.tmp

QCC -c -g main.cpp

QCC -Vgcc_ntox86 -g osiBus.o tSTC.o tESeries.o main.o -o main

main.o: In function `tSTC::tAI_START_STOP_Select::setRegister(unsigned
short, nMDBG::tStatus2 *)’:

/cygdrive/u/PFE/PCIDrivers/tSTC.ipp(.text+0x2e5): undefined reference to
`std::terminate(void)’

main.o: In function `test(iBus *)’:

/cygdrive/u/PFE/PCIDrivers/main.cpp:160: undefined reference to
`std::terminate(void)’

cc: C:/QNX630/host/win32/x86/usr/bin/ntox86-ld caught signal 1

make: *** [main] Error 1

make: Target `all’ not remade because of errors.

I searched for a file contaning the function terminate but in vain. None of
all the files I’m using in my project contains the function std::
terminate().
If someone could help resolve this problem it will be very appreciated.
Thank you

Normally, you would get this by linking with the cpp lib.
Try adding the following in your code.

namespace std {

void terminate( void ) {

abort();

}

}

“hamza” <hamza.elkouch@polymtl.ca> wrote in message
news:fa294v$kmt$1@inn.qnx.com

Hi,
I’m trying to build an application using MHDDK to develop drivers for
PCI-6025E NI board.
I’m using the makefile pasted below.
When I build the projet I have these errors that I can’t resolve.

make -k EXTRA_SUFFIXES=cpp all --file=U:/PFE/PCIDrivers/QMakefile9347.tmp

QCC -c -g main.cpp

QCC -Vgcc_ntox86 -g osiBus.o tSTC.o tESeries.o main.o -o main

main.o: In function `tSTC::tAI_START_STOP_Select::setRegister(unsigned
short, nMDBG::tStatus2 *)’:

/cygdrive/u/PFE/PCIDrivers/tSTC.ipp(.text+0x2e5): undefined reference to
`std::terminate(void)’

main.o: In function `test(iBus *)’:

/cygdrive/u/PFE/PCIDrivers/main.cpp:160: undefined reference to
`std::terminate(void)’

cc: C:/QNX630/host/win32/x86/usr/bin/ntox86-ld caught signal 1

make: *** [main] Error 1

make: Target `all’ not remade because of errors.

I searched for a file contaning the function terminate but in vain. None
of all the files I’m using in my project contains the function std::
terminate().
If someone could help resolve this problem it will be very appreciated.
Thank you

Thank you
i added the code to mine and it works perfectly.
Thanks
“Garry Turcotte” <garry@qnx.com> wrote in message
news:fa2rng$shl$1@inn.qnx.com

Normally, you would get this by linking with the cpp lib.
Try adding the following in your code.

namespace std {

void terminate( void ) {

abort();

}

}

“hamza” <> hamza.elkouch@polymtl.ca> > wrote in message
news:fa294v$kmt$> 1@inn.qnx.com> …
Hi,
I’m trying to build an application using MHDDK to develop drivers for
PCI-6025E NI board.
I’m using the makefile pasted below.
When I build the projet I have these errors that I can’t resolve.

make -k EXTRA_SUFFIXES=cpp all --file=U:/PFE/PCIDrivers/QMakefile9347.tmp

QCC -c -g main.cpp

QCC -Vgcc_ntox86 -g osiBus.o tSTC.o tESeries.o main.o -o main

main.o: In function `tSTC::tAI_START_STOP_Select::setRegister(unsigned
short, nMDBG::tStatus2 *)’:

/cygdrive/u/PFE/PCIDrivers/tSTC.ipp(.text+0x2e5): undefined reference to
`std::terminate(void)’

main.o: In function `test(iBus *)’:

/cygdrive/u/PFE/PCIDrivers/main.cpp:160: undefined reference to
`std::terminate(void)’

cc: C:/QNX630/host/win32/x86/usr/bin/ntox86-ld caught signal 1

make: *** [main] Error 1

make: Target `all’ not remade because of errors.

I searched for a file contaning the function terminate but in vain. None
of all the files I’m using in my project contains the function std::
terminate().
If someone could help resolve this problem it will be very appreciated.
Thank you