How to merge from Makefiles to CLion CMake

I am an old Linux/Emacs/make dude now retired I try to learn new stuff :-)

I have an old Linux project that is based on Makefiles building with C starting from top level and building libs and executables in sub-directories in the correct order.

I just included the files into CLion to evaluate the product. I am happy so far but for several features to work I apparently have to use CMake.

Is there a somewhat straightforward way to accomplish this?

I have tried to follow the “Simple setup” that assumes one binary or library but that will obviously not work.

Any help is greatly appreciated

0

Hello!

I am happy so far but for several features to work I apparently have to use CMake.

Could you please specify the features you're interested in? Are those Google Sanitizers and Code Coverage?

0

Could you please specify the features you're interested in? Are those Google Sanitizers and Code Coverage?

I stay away from anything DDR Stasi (AKA Google) if possible

But as far as I have found out handy things like Refactor, jumping to usage or definition and maybe debugging does not work with Makefile projects (I have version 2023.3.3)

0

All these features should work for Makefile projects. Just in case, you can find the table listing features that are supported for each of the project formats here - https://www.jetbrains.com/help/clion/project-models.html.

Please do the following:

  1. Close your Makefile project in CLion (File | Close Project);
  2. Remove the .idea subdirectory from the project directory;
  3. On the Welcome to CLion screen, select Open and follow these instructions starting at step 2.

Is the project loaded successfully as a result? Or do you get any errors/warnings in the Build tool window?

0

请先登录再写评论。