Search code examples
linkerdebianeclipse-cdtlinker-errorsopenscenegraph

linker on debian does not see symlined shared libs


I have got this error:

/usr/bin/ld: cannot find -llibosg

while GCC C++ Linker invoked with:

g++ -i -L/home/user/osg/lib -o"WCC"  [my files] -llibosg -llibOpenThreads -llibosgQt -llibosgViewer -llibosgText

command locate libosg.so returns:

/home/user/osg/lib/libosg.so
/home/user/osg/lib/libosg.so.3.1.3
/home/user/osg/lib/libosg.so.92
/usr/lib/libosg.so.28.3
/usr/lib/libosg.so.65
/usr/local/lib/libosg.so
/usr/local/lib/libosg.so.3.1.3
/usr/local/lib/libosg.so.92

I've switched from Win, where everything works fine. I'm using Eclipse. Why linker doesn't see those libraries ?


Solution

  • Shouldn't that be -losg? Remove the lib part from all the -ls.