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

Revision history [back]

click to hide/show revision 1
initial version

As documented by CMake (https://cmake.org/cmake/help/v3.5/command/file.html):

We do not recommend using GLOB to collect a list of source files from your source tree. If no CMakeLists.txt file changes when a source is added or removed then the generated build system cannot know when to ask CMake to regenerate.

If you glob the files instead of listing them explicitly CMake has no way of knowing when it needs to reconfigure. Therefore you should list them explicitly. Otherwise you need to force the CMake invocation.