Ask Your Question
0

laser geometry and Eigen/Core bug - how to actually fix it ?

asked 2014-11-25 10:25:09 -0500

Erwan R. gravatar image

updated 2014-11-28 09:14:51 -0500

Hello !

I've been planning to use PointCloud for processing some laser data from PR2 tilt scan, but when including <laser_geometry/laser_geometry.h>, I'm the case of Eigen/Core bug (Ubuntu 12.04 / Groovy).

I add a look to the proposed solution which is about modifying the CMakeLists. It seems that the problem has been solved (according to the ticket), but it is still there in my up-to-date groovy laser_geometry package. I don't really understand if I have to make a manual modification (my package is in /opt/ros/groovy/share/laser_geometry and only contains a package.xml and a cmake folder - no CMakeLists.txt) or if I should just reinstall something (from apt-get install, I get that my package is up-to-date). The bug exists also on the real PR2.

Ticket corresponding : https://code.ros.org/trac/ros-pkg/tic...

Thanks for reading, Erwan

EDIT after ahendrix answer :

I'm building packages with catkin.

I depend on the following packages (build_depend tag in package.xml) : roscpp geometry_msgs tf sensor_msgs laser_geometry message_generation

after checking, all packages have at least a cmake folder with *Config.cmake and *Config-version.cmake and a package.xml files. Laser_geometry and message_generation have nothing else, others contains msg and srv folders. In my understanding, there are all catkinized.

I added :

find_package(Eigen REQUIRED)
include_directories(${Eigen_INCLUDE_DIRS})

to my_package/CMakeLists.txt and it's now compiling without error, I'm able to declare a LaserProjector. What I wasn't really understanding with the previous solutions was where to make this fix (as there is no CMakeLists.txt in the laser_geometry package accessible from roscd).

Thanks ahendrix !

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
1

answered 2014-11-28 08:02:49 -0500

ahendrix gravatar image

This has been fixed for almost two years. If you're running into it now, it probably means that there's something wrong with the way you're building your package.

Since you're on Groovy, are you using rosbuild or catkin as your build system? Are all of dependencies cakinized properly? laser_geometry is a catkinized package, so you should be able to use either.

It may be that laser_geometry isn't exporting the dependency on Eigen correctly. If you're using catkin, you should be able to fix this by finding Eigen in your package's CMakeLists.txt:

find_package(Eigen REQUIRED)
include_directories(${Eigen_INCLUDE_DIRS})
edit flag offensive delete link more

Comments

Edited my question, it's working ! Thank you !

Erwan R. gravatar image Erwan R.  ( 2014-11-28 09:15:25 -0500 )edit

The original question, bug and answer that you linked to was for the rosbuild version of laser_geometry. Now that laser_geometry is catkinized, the install process is simpler and the install layout is very different; much closer to a traditional FHS layout, which is why the old answers didn't apply.

ahendrix gravatar image ahendrix  ( 2014-11-29 18:08:56 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2014-11-25 10:25:09 -0500

Seen: 762 times

Last updated: Nov 28 '14