Skip to content

Costmap Constructor fails to load plugin #151

@mrnobody1313

Description

@mrnobody1313

I have two packages that I define my plugins in them, costmap_2d, and my_costmap. Plugin files in my_costmap package are as below

my_costmap_plugins.xml:

<library path="lib/libmy_costmap_layer">
  <class type="my_costmap::ProbabilisticLayer"  base_class_type="costmap_2d::Layer">
    <description>Listens to ...</description>
  </class>
  <class type="my_costmap::SpecifiedCostLayer"  base_class_type="costmap_2d::Layer">
    <description>Listens to...</description>
  </class>
</library>

package.xml

<export>
    <costmap_2d plugin="${prefix}/my_costmap_plugins.xml"/>
  </export>

specified_cost_layer.cpp
Added PLUGINLIB_EXPORT_CLASS(my_costmap::SpecifiedCostLayer, costmap_2d::Layer)

In another package (my_package_2), I created an instance of costmap2DROS as

costmap_ = new costmap_2d::Costmap2DROS("costmap", tf_);

Once plugin_loader_.createInstance() is called in costmap2dROS pluginlib first loads costmap_2d plugins properly. However once it wants to load my_costmap::SpecifiedCostLayer, my_costmap_layer.so is found but I get a SIGABRT with the follwing error

ERROR: flag 'log_prefix' was defined more than once (in files 'src/base/logging.cc' and 'src/logging.cc').
my_package_2: /usr/include/boost/thread/pthread/recursive_mutex.hpp:104: boost::recursive_mutex::~recursive_mutex(): Assertion `!pthread_mutex_destroy(&m)' failed.

Any idea?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions