Closed Scotty1701 closed 1 year ago
This CMake flag is only implemented for Makefile Generators and Ninja (https://cmake.org/cmake/help/latest/variable/CMAKE_EXPORT_COMPILE_COMMANDS.html). Ninja is supported on Windows, so I recommend using that instead of the default generator.
I'm attempting to generate a
compile_commands.json
file for use withclangd
, however the file is not generated (neither on a package level nor the workspace level). Attempting to build theturtlesim
package fromros_tutorials
withgives the following warning:
My platform is Windows 10 with Ros2 Foxy installed from the aka.ms/ros Chocolatey package.
I build colcon from source following the instructions in the docs, and
colcon version-check
gives:Attempting the same in an Ubuntu 20.04 with identical colcon versions correctly generates
compile_commands.json
on a package and workspace level.I also tested on windows with the change proposed in #114, however this did not result in any changed behavior. Additionally, I tested ommitting the
--merge-install
option, which produced no change for either platform.