c++ - Eclipse CDT: how to import external libraries? -
i new @ c++ , @ eclipse. trying use open dynamic engine. using ubuntu 12.04.2 lts.
i downloaded ode sourceforge , compiled using instruction using make. @ end of process, files libode.a , libode.la present in usr/local/lib.
demos delivered program run well.
i trying use ode eclipse cdt (juno service release 2).
i created project , wrote ultra-minimum program:
#include <ode/ode.h> int main() { return 0; }
first did not change properties of project @ all. default /usr/local/include in includes , eclipse not complain not finding ode.h.
when run program 1057 errors of like:
a not declared in scope | line 134,external location: /usr/local/include/ode/matrix.h
looks trying recompile ode ?
i wondered if because not find libraries, , edited properties of project. @ properties / c/c++ build / settings / cross g++ linker / libraries add "ode" @ libraries , "/usr/local/lib" in library search path.
this did not change anything.
anything not ?
---- edit
apparently eclipse running:
g++ -o0 -g3 -wall -c -fmessage-length=0 -mmd -mp -mf"src/testode.d" -mt"src/testode.d" -o "src/testode.o" "../src/testode.cpp"
i ran in terminal , same errors
running make install
not best way install things on modern linuxes. try installing libode-dev
package instead (sudo apt-get install libode-dev
). also, should remove manually installed ode beforehand.
Comments
Post a Comment