We have an existing embedded project(STM32L) that uses CMake as the build system. Usage of CMake is considered highly imperative in our case since we make many target builds, unit tests that run both on target and PC etc.
Do you have any support(may be cmake plugin support) that enables us to generate VisulaGDB solution from a CMake system ?
I have been using VisualGDB for debugging the same project by importing the entire project as a CMake project through VisualGDB, but currently facing several issues when compiling since it emits some errors related to external scripts used by the build system. I can post the errors if needed, but wondering whether if there’s any support to create VisualGDB solution out of the source code which will eliminate all the troubles that I’m facing right now.
VisualGDB uses a different approach when dealing with CMake projects. Instead of generating a second project from the CMakeLists.txt files, VisualGDB can open the CMake project directly as a regular Visual Studio project. This is fully supported for Linux targets (see this tutorial) and is partially supported for embedded targets (importing existing code is supported, but features like Embedded Frameworks won’t work yet).
We would advise trying VisualGDB 5.4 Preview 3 and importing your project by selecting “Create a project built with command-line tools” -> “Import a CMake project” -> “Use the advanced CMake Project Subsystem”. If this doesn’t work, please let us know more about the errors you encounter and we can help you resolve them.