ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

errors compiling rgbdslam, g2o errors about cholmod

asked 2012-01-15 12:10:43 -0600

arsenix gravatar image

updated 2014-01-28 17:11:08 -0600

ngrennan gravatar image

Hello! I am trying to build rgbdslam and not having much luck. I am using Ubuntu 11.10 64 bit. I have latest ros electric installed. I pulled the latest rgbdslam (from http://www.informatik.uni-freiburg.de/~endres/rgbdslam/rgbdslam.tgz). I also pulled g2o from svn. g2o builds fine and all dependencies pulled down and built when I did a "rosmake --rosdep-install rgbdslam". Initially I was getting some errors related to undefined references and it appeared that the g2o libs were not being linked in. So I added all the libg2o* libraries to rgbdslam's CMakeLists.txt. This got me further but some errors remain and I'm not sure where these dependencies are.

Here is an excerpt from my buildfailures-with-context.txt:

[ 29%] Built target rosbuild_precompile
make[3]: Entering directory `/home/jpeverill/.ros/localstacks/rgbdslam/build'
make[3]: Leaving directory `/home/jpeverill/.ros/localstacks/rgbdslam/build'
make[3]: Entering directory `/home/jpeverill/.ros/localstacks/rgbdslam/build'
Linking CXX executable ../bin/rgbdslam
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `LinearSolverCholmod':
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:75: undefined reference to `cholmod_start'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:75: undefined reference to `cholmod_start'
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `g2o::LinearSolverCholmod<Eigen::Matrix<double, 6, 6, 0, 6, 6> >::init()':
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:98: undefined reference to `cholmod_free_factor'
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `~LinearSolverCholmod':
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:89: undefined reference to `cholmod_free_factor'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:92: undefined reference to `cholmod_finish'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:89: undefined reference to `cholmod_free_factor'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:92: undefined reference to `cholmod_finish'
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `g2o::LinearSolverCholmod<Eigen::Matrix<double, 6, 6, 0, 6, 6> >::computeSymbolicDecomposition(g2o::SparseBlockMatrix<Eigen::Matrix<double, 6, 6, 0, 6, 6> > const&)':
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:252: undefined reference to `cholmod_analyze'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:278: undefined reference to `cholmod_amd'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:301: undefined reference to `cholmod_analyze_p'
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `g2o::LinearSolverCholmod<Eigen::Matrix<double, 6, 6, 0, 6, 6> >::solvePattern(g2o::SparseBlockMatrix<Eigen::Matrix<double, -1, -1, 0, -1, -1> >&, std::vector<std::pair<int, int>, std::allocator<std::pair<int, int> > > const&, g2o::SparseBlockMatrix<Eigen::Matrix<double, 6, 6, 0, 6, 6> > const&)':
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:202: undefined reference to `cholmod_factorize'
/home/jpeverill/.ros/localstacks/g2o/include/g2o/solvers/cholmod/linear_solver_cholmod.h:207: undefined reference to `cholmod_change_factor'
CMakeFiles/rgbdslam.dir/src/graph_manager.o: In function `g2o::LinearSolverCholmod<Eigen::Matrix<double, 6, 6, 0, 6, 6> >::solve(g2o::SparseBlockMatrix<Eigen::Matrix<double, 6, 6 ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
5

answered 2012-01-16 12:59:36 -0600

arsenix gravatar image

Ok I think I fixed this one. Didn't realize cholmod was an external library called by g2o/eigen.

I changed the following line in the CMakeLists.txt to add the cholmod library and all the g2o libs to the rgbdslam build: SET(LIBS_LINK rgbdslam GL GLU cholmod g2o_cli g2o_core g2o_incremental g2o_interactive g2o_interface g2o_math_groups g2o_parser g2o_solver_cholmod g2o_solver_csparse g2o_solver_dense g2o_solver_pcg g2o_stuff g2o_types_icp g2o_types_sba g2o_types_sim3 g2o_types_slam2d g2o_types_slam3d ${QT_LIBRARIES} ${QT_QTOPENGL_LIBRARY} ${GLUT_LIBRARY} ${OPENGL_LIBRARY} ${OpenCV_LIBS})

With this addition it builds... now on to the next challenge :)

edit flag offensive delete link more

Comments

Well done. This problem occured to me too last week after upgrading from ubu 11.04 to 11.10. If you have further problems let me know. I updated the google code repository (see http://ros.org/wiki/rgbdslam) with the latest Version of rgbdslam. It hasn't been thoroughly tested though.
Felix Endres gravatar image Felix Endres  ( 2012-01-16 19:13:44 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2012-01-15 12:10:43 -0600

Seen: 3,734 times

Last updated: Jan 16 '12