elevation_mapping icon indicating copy to clipboard operation
elevation_mapping copied to clipboard

Cases when elevation_mapping crashes due to compiler settings

Open peci1 opened this issue 5 years ago • 0 comments

In this issue I'd like to collect the cases when elevation_mapping segfaults because of incompatible compiler settings (because I've found at least two settings that make it crash). Feel free to add a reference or comment to your segfaults...

  1. ROS Indigo, Ubuntu 14.04, PCL 1.7 installed by system, building in Debug mode: the built binary crashes at startup because of incompatibilities between c++11 support and PCL 1.7.
    • Solution: Build in Release or RelWithDebInfo modes
    • Solution: Compile PCL on your own
    • Possibly relevant issues: #33, #49
    • Possible fix in elevation_mapping: As stated in #33, this probably can't be fixed for Indigo.
  2. ROS Indigo, Ubuntu 14.04, building with gcc 4.9 with optimizations (Release or RelWithDebInfo): the built binary crashes when fusing maps (in a call to GridMap::add). For some reason, the call to add is performed with uninitialized values for some vector lengths, resulting in an attempt to allocate a vector of random size, which often doesn't fit into available memory.
    • Solution: Build with gcc 4.8 or 5+.
    • Possibly relevant issues: #77, #42
    • Possible fix in elevation_mapping: I still haven't digged deep enough to find the culprit why gcc 4.9 fails. So I'd suggest checking the compiler version in CMakeLists.txt and failing the build when gcc 4.9 is detected. OpenMesh does something like this, though I haven't found any description of the gcc bug they faced.

peci1 avatar Nov 06 '18 14:11 peci1