Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Force config. regeneration when adding new params #58

Open
corot opened this issue Mar 19, 2018 · 5 comments
Open

Force config. regeneration when adding new params #58

corot opened this issue Mar 19, 2018 · 5 comments

Comments

@corot
Copy link
Collaborator

corot commented Mar 19, 2018

When adding new params to https://github.com/magazino/move_base_flex/blob/master/mbf_abstract_nav/src/mbf_abstract_nav/__init__.py, you need to touch https://github.com/magazino/move_base_flex/blob/master/mbf_costmap_nav/cfg/MoveBaseFlex.cfg before compiling so code for the new parameters is generated.

Cannot do better?

@corot
Copy link
Collaborator Author

corot commented Jun 16, 2019

One ugly option is to always touch the .cfg file, but this makes compilation longer when only it's occasionally needed:

  • file(TOUCH_NOCREATE cfg/MoveBaseFlex.cfg) requires CMake 3.12
    or
  • execute_process(COMMAND touch cfg/MoveBaseFlex.cfg)

@jspricke
Copy link

You would need to add the file as a dependency to the add_custom_command in the generate_dynamic_reconfigure_options macro, i.e. here:
https://github.com/ros/dynamic_reconfigure/blob/melodic-devel/cmake/dynamic_reconfigure-macros.cmake#L73
Maybe an extra parameter in for the macro works.
I didn't find a way to inject the dependency later.

@corot
Copy link
Collaborator Author

corot commented Jun 25, 2019

Maybe an extra parameter in for the macro works.

Unfortunately not; generate_dynamic_reconfigure_options tries to process it as any other .cfg file

@jspricke
Copy link

jspricke commented Jun 25, 2019 via email

@corot
Copy link
Collaborator Author

corot commented Jun 25, 2019

Change PRequested. @jspricke, maybe you can comment it, if it's not described clearly enough.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants