Error compiling g2o for RGBD-Slam
I tried to compile g2o for rgbd-slam, but it fails with:
Linking CXX shared library ../../../../lib/libg2o_types_icp.dylib
[ 84%] Built target types_icp
Scanning dependencies of target solver_pcg
[ 86%] Building CXX object g2o/solvers/pcg/CMakeFiles/solver_pcg.dir/solver_pcg.cpp.o
Linking CXX shared library ../../../../lib/libg2o_solver_pcg.dylib
Undefined symbols for architecture x86_64:
"std::set<g2o::HyperGraph::Edge*, std::less<g2o::HyperGraph::Edge*>, std::allocator<g2o::HyperGraph::Edge*> >::size() const", referenced from:
g2o::BlockSolver<g2o::BlockSolverTraits<7, 3> >::solve() in solver_pcg.cpp.o
g2o::BlockSolver<g2o::BlockSolverTraits<6, 3> >::solve() in solver_pcg.cpp.o
g2o::BlockSolver<g2o::BlockSolverTraits<3, 2> >::solve() in solver_pcg.cpp.o
g2o::BlockSolver<g2o::BlockSolverTraits<-1, -1> >::solve() in solver_pcg.cpp.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [../lib/libg2o_solver_pcg.dylib] Error 1
make[1]: *** [g2o/solvers/pcg/CMakeFiles/solver_pcg.dir/all] Error 2
make: *** [all] Error 2
ROS Fuerte on OSX 10.7.3
What am I missing?
Make sure the libg2o_solver_pcg.dylib library has x86_64 symbols.