I'm trying to start a project using TouchGFX on stm32H743IIT6 and I generated the project with CubeMX, and when I try to build the project with Clion, there are errors about simulator source files.So I excluded all directories about simulators in cmakelists, and compiling seems to work but there are errors of multiple definition of functions, and after checking, I found that all these multiple definition errors are related to functions in OSWrappers.cpp and OSWrappers_cmsis.cpp. Then I tried to open project in CubeIDE and compile with it, and there are no errors this time, everything is fine. I also tried to generate the project in MDK-ARM form and build it in Keil, still no problem. It seems only Clion can't build the project properly and I'm wondering if there's a way to compile in Clion.
To use another IDE, you first need to use the correct compiler. Good for you, JetBrains also have documentation about that : how-to-switch-compilers-in-clion .
Basically, you need to set the same gcc as the one we are using.
Thanks for reply, after reading your suggestions, I tested My Clion build setup and it should be fine since I managed to build simple projects generated from CubeMX. After this, I excluded files in TouchGFX/target and OSWrappers_cmsis.cpp, and now the problem is undefined reference about some functions. Maybe it's because of the generated Cmakelists contains problems? Should I attempt to write my own Cmakelists?
I understand what you mean now, porting the make files does seem kinda tricky, so I'm gonna try working on this for a while and if it still doesn't work out in next few days, I'll just compile with some other IDEs.
I do not have any experience with generated CMakeLists. In general ST only just started with some support for CMake, will take some time before it gets mature. If you have undefined references you have to add the missing files to the CMakeLists.
I downloaded MinGW/cygwin/mingw-w64 not one of them work. I can't find the issue, every time CMake - Bundled "!Does not work in this environment".I watched youtube for clion-setup more than one. I followed them step by step, same error ??the issue is whatever Environment I chose non one of them work CMake give me error (CMake - Bundled "!Does not work in this environment) . what I know 90% it must detect auto. I delete mingw/w64/cygwin & reinstall them(Each one alone), I did path in system variables, I missed something, I don't know what. And thank you all for your help I appreciate that.
I had the same problem as god, the debugger wasn't displaying stl containers correctly. When I tried to enable the bundled gdb and cmake, there was no option. Installing clion through jetbrains-toolbox fixed the problem.
Recently, whenever I start debugging, a box appears at the bottom-left saying: Error during pretty printers setup: Error while executing Python code. Some features and performance optimizations will not be available.
I did some web search, and it seems that the solution is using the "bundled GDB". I used the GDB in the Arch repository. What is the easiest solution to solve this problem? Debugging seems to work normally anyway, so at least I want to suppress that box from appearing.
Hi had some troubles starting CLion on my Mac M1 and fixed (more of a workaround since JetBrains is not supporting it officially) the aarch64 build with a compatible jbr build and fsnotifier. Here is my patch:
7fc3f7cf58