because my attempts to use cppunit constantly fail (see my post "linker errors: ..."), I wondered if perhaps my cppunit rpm contains a lib that is compiled with gcc 3.x while we use 2.95.3 for out software.
So I tried to compile cppunit-1.10.2 with our gcc 2.95.3 and it failed:
/usr/bin/ld: .libs/libcppunit-1.10.so.2.0.0: undefined versioned symbol name __dynamic_cast@@CXXABI_1.2
/usr/bin/ld: failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status
make[2]: *** [libcppunit.la] Error 1
make[2]: Leaving directory `/mnt/ext1/home/gru/src/cppunit-1.10.2/src/cppunit'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/mnt/ext1/home/gru/src/cppunit-1.10.2/src'
make: *** [all-recursive] Error 1
Compiling with gcc 3.3 worked fine. Is it possible to compile cppunit with gcc 2.95 ?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I fetched version 1.5.5 of cppunit, which compiles fine with gcc 2.95.3. It may be a little ancient, but what the heck...
Unfortunately I still can't test my application. Compilation failes with:
unittest.cpp:15: `TestRunner' undeclared (first use this function)
TestRunner is used as mentioned in the cookbook.html:
int main (int ac, char **av) {
TestRunner runner;
runner.addTest (ExampleTestCase::suite ());
runner.addTest (ComplexNumberTest::suite ());
runner.run ();
return 0;
}
Where the hell is TestRunner defined ?
find /usr/local/include/cppunit/ -type f -exec grep -il TestRunner {} \;
gives me nothing....
I'm a bit frustrated. For a software that should help me make better programs, it is quite hard to get it working...
Please help me,
Markus
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
p.s. The documentation URL I gave is for version 1.10.2. To get the documentation for the older version you are using, either see if it is included with what you already downloaded or check the site for older documentation (either online or available for download).
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
because my attempts to use cppunit constantly fail (see my post "linker errors: ..."), I wondered if perhaps my cppunit rpm contains a lib that is compiled with gcc 3.x while we use 2.95.3 for out software.
So I tried to compile cppunit-1.10.2 with our gcc 2.95.3 and it failed:
/usr/bin/ld: .libs/libcppunit-1.10.so.2.0.0: undefined versioned symbol name __dynamic_cast@@CXXABI_1.2
/usr/bin/ld: failed to set dynamic section sizes: Bad value
collect2: ld returned 1 exit status
make[2]: *** [libcppunit.la] Error 1
make[2]: Leaving directory `/mnt/ext1/home/gru/src/cppunit-1.10.2/src/cppunit'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/mnt/ext1/home/gru/src/cppunit-1.10.2/src'
make: *** [all-recursive] Error 1
Compiling with gcc 3.3 worked fine. Is it possible to compile cppunit with gcc 2.95 ?
Ok, I'm not giving up.
I fetched version 1.5.5 of cppunit, which compiles fine with gcc 2.95.3. It may be a little ancient, but what the heck...
Unfortunately I still can't test my application. Compilation failes with:
unittest.cpp:15: `TestRunner' undeclared (first use this function)
TestRunner is used as mentioned in the cookbook.html:
int main (int ac, char **av) {
TestRunner runner;
runner.addTest (ExampleTestCase::suite ());
runner.addTest (ComplexNumberTest::suite ());
runner.run ();
return 0;
}
Where the hell is TestRunner defined ?
find /usr/local/include/cppunit/ -type f -exec grep -il TestRunner {} \;
gives me nothing....
I'm a bit frustrated. For a software that should help me make better programs, it is quite hard to get it working...
Please help me,
Markus
See the documentation at http://cppunit.sourceforge.net/doc/lastest/index.html
In particular, http://cppunit.sourceforge.net/doc/lastest/class_test_runner.html says you need
#include <TestRunner.h>
p.s. The documentation URL I gave is for version 1.10.2. To get the documentation for the older version you are using, either see if it is included with what you already downloaded or check the site for older documentation (either online or available for download).