0

I'm using NetBeans 7.1 on Windows 7. I downloaded the CUnit archive and used shell scripts supplied with the archive to install it ($make install, etc.). I'm using Cygwin as my compiler, and whenever I try to build the unit test, I get the following error:

/usr/lib/gcc/i686-pc-cygwin/4.3.4/../../../../i686-pc-cygwin/bin/ld: cannot find -lcunit

Obviously, the linker (ld) doesn't know where to look for something, but I don't know the intricacies of how this stuff works. Searching for lcunit on my computer didn't return anything except for the makefile of this project.

One thing I think I should mention is that when I installed CUnit, NetBeans did not know where to look for it. It got installed into /usr/local/ and this was not one of the paths NetBeans parsed.

DIF
  • 2,470
  • 6
  • 35
  • 49
Phonon
  • 12,549
  • 13
  • 64
  • 114

1 Answers1

2

"-lcunit" is just a flag/option instructing your compiler to link all cunit stuff in your app. usage could be something like this (gcc):

gcc test.c -lcunit -o test

looks like your compiler doesn't know what to do with this flag... :/

Ivica
  • 366
  • 1
  • 5
  • Yeah, you're pretty much right. I didn't have CUnit installed for Cygwin. So yeah, my compiler didn't know about the flag. – Phonon Apr 19 '12 at 15:15