1

I'm using Geany in Ubuntu as an IDE for a C++ Project, and I want to use some external libraries (from Webots). However, I don't find the option to specify additional library paths (as one can find in Code::Blocks or Netbeans). Must I specify the paths manually as a build option? If so, how do I do it? I'm not exactly an expert at this kind of stuff.

1

As far as I know, we can specify additional libraries in the Project Properties (Project -> Properties) as shown in the picture

enter image description here

| improve this answer | |
  • Yes, that's the place. However, I need to specify both the libraries for the linker and the include directories for the compiler. I've been using -L for the first and -I for the second, and it compiles successfully, but it doesn't build (some "undefined references" errors). Am I doing something wrong? – João André Apr 13 '13 at 18:41
  • Can you please post the complete command which you are using? – thefourtheye Apr 13 '13 at 18:42
  • g++ -Wall -c "src/%f" -L "/usr/local/webots/lib/libController.so" -L "/usr/local/webots/lib/libCppController.so" -L "../../lib/OPKinematics/lib/libOPKinematics64.a" -L "/usr/local/webots/resources/projects/robots/darwin-op/libraries/darwin/libdarwin.so" -I "../../lib/OPKinematics/include" -I "../../lib/include" -I "/usr/local/webots/include/controller/cpp" -I "/usr/local/webots/include/controller/c" – João André Apr 13 '13 at 18:53
  • Can you try and replace all the relative paths with absolute paths? – thefourtheye Apr 13 '13 at 18:59
  • Already tried it, still doesn't build. I'm getting several errors of the type: main.cpp:(.text+0x33): undefined reference to webots::DarwinRobot::savePosition()' – João André Apr 13 '13 at 19:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.