Author Topic: cmake generator for cbp files  (Read 4779 times)

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5490
cmake generator for cbp files
« on: August 27, 2018, 02:54:46 pm »
is there anyone who has experience on using cmake to also generate codeblocks project files ?
How does it work < what is the command on cmake to activate this ?
Code
cmake ../ -G 'CodeBlocks - Unix Makefiles'


And what is the current state, at some time there were questions here to have cmake generate native cbp files, and not just based upon the also generated makefile.

And what with workspaces ... ?
« Last Edit: August 27, 2018, 02:57:22 pm by killerbot »

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: cmake generator for cbp files
« Reply #1 on: August 27, 2018, 08:06:34 pm »
I'm using it daily to develop quite big commercial software...

It works well if you don't want to run or debug the resulting binaries directly. I'm fine starting the executable from the command line and attaching to already working executable.

The cmake produces a single project which has all the files in the project and every cmake target is a target in the project and could be built. Workspaces doesn't matter.

Making cmake to generate native projects is almost impossible, because our native projects probably doesn't have all the scripting features cmake provides. The vstudio generator generates native projects and I'm not sure the results are really good.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5490
Re: cmake generator for cbp files
« Reply #2 on: August 27, 2018, 09:54:06 pm »
It works well if you don't want to run or debug the resulting binaries directly. I'm fine starting the executable from the command line and attaching to already working executable.


Can you then put the breakpoints within CB ?
And does the code completion works rather ok, or is it worse then whenyou would have a workspace made out of CB projects (cbp's) ?

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: cmake generator for cbp files
« Reply #3 on: August 28, 2018, 09:53:13 am »
The debugger works fine if you use debug -> attach. Debug -> Start doesn't work (at least for our project).
Code completion works fine (with its limitations of course). Generally CC works better if you have a single project.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]