1

I'm trying to set my CUnit on Eclipse but I got two errors:

  • If I lunch without -lcunit parameter I have:

undefined reference to CU_assertImplementation

  • If I lunch with -lcunit I have:

bin/ld.exe: skipping incompatible lib/libcunit.a when searching for -lcunit

Where am I wrong? There is a good tutorial on how to install?

Windows is the O.S.

granmirupa
  • 2,780
  • 16
  • 27
  • I successfully compiled the example of cunit [there](http://cunit.sourceforge.net/example.html). I installed the packages Cunit and cunit-dev. I created a c project using the example and I added `cunit` in project properties/C C++ Build/Settings/GCC linker/Libraries/libraries(-l). The linker command becomes `gcc -o "unittest" ./src/unittest.o -lcunit` and everything worked fine. My guess is that you are working on windows and eclipse tried to link a windows executable to a library intended for MinGW or something similar. – francis Jun 09 '16 at 21:45
  • @francis yes I'm on windows – granmirupa Jun 09 '16 at 21:55

0 Answers0