CMake 3.0.0

Discussion area about developing or extending OGRE, adding plugins for it or building applications on it. No newbie questions please, use the Help forum for that.
Post Reply
User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

CMake 3.0.0

Post by Klaim »

A short heads-up for the Ogre team for future CMake scripts improvements:
CMake 3.0.0 as just been released (after a long release candidate process).
Basically there is a lot of features that clarify or simplify the declarations of targets, interdependencies and requirements (like making sure all targets depending on another target will automatically include the dependencies headers).
Also they migrated (and rewrote apparently in a clearer way) the official documentation using Sphinx (the Python doc generator).

Anyway, here is the new manual/introduction which summarize the idiomatic use of the new features: http://www.cmake.org/cmake/help/v3.0/ma ... tem.7.html
And here is the release note: http://www.cmake.org/pipermail/cmake/20 ... 57793.html

Of course I don't expect the Ogre team to refactor the CMake code right now but I will do so for my own project to reduce CMake script complexity (and augment maintainability by myself at least) and I was thinking that you might want to know that these features could help (as Ogre as a massive amount of code which could be refactored using the new interface features I think).

User avatar
spacegaier
OGRE Team Member
OGRE Team Member
Posts: 4293
Joined: Mon Feb 04, 2008 2:02 pm
Location: Germany
x 127
Contact:

Re: CMake 3.0.0

Post by spacegaier »

I see a pull request for Ogre from your side in the near future, once you are fluent in CMake 3.0 ;) . Otherwise, the team might eventually tackle that.
Ogre Admin [Admin, Dev, PR, Finance, Wiki, etc.] | BasicOgreFramework | AdvancedOgreFramework
Don't know what to do in your spare time? Help the Ogre wiki grow! Or squash a bug...

User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Re: CMake 3.0.0

Post by Klaim »

spacegaier wrote:I see a pull request for Ogre from your side in the near future, once you are fluent in CMake 3.0 ;) . Otherwise, the team might eventually tackle that.
I sincerely wish I could do that to help Ogre (among other things) but my time with CMake makes me think I still don't understand everything about it and it's highly frustrating (so I always feel like a noob).
But I do see some simple possible enhancements anyway so yes sure I will consider doing a pull request if I find enough time just after improving my own code.
Wish me good luck! *dive in build-system hell*

Transporter
Minaton
Posts: 933
Joined: Mon Mar 05, 2012 11:37 am
Location: Germany
x 110

Re: CMake 3.0.0

Post by Transporter »

Ogre's build system is one of the best in the opensource world, because it's working out of the box without modifying dependencies or doing some other crazy shit with additional required programs. :D

The worst example for a build system has OpenModelica (https://openmodelica.org/). Building OM under windows is like spending your holidays in hell :twisted:. You have to install a dev package with mingw, eclipse and cmake. OM only supports gcc. The main build system has been built on top of autoconf and some parts are using cmake. Also, the dev package consists of old library versions.

@Klaim
I'll have a look at Cmake 3, too. I could try to help you - If you like.

User avatar
FrameFever
Platinum Sponsor
Platinum Sponsor
Posts: 414
Joined: Fri Apr 27, 2007 10:05 am

Re: CMake 3.0.0

Post by FrameFever »

Klaim wrote: I sincerely wish I could do that to help Ogre (among other things) but my time with CMake makes me think I still don't understand everything about it and it's highly frustrating (so I always feel like a noob).
...
Wish me good luck! *dive in build-system hell*
When you don't like this build system, why do you use it anyway?

Do you know QBS? http://qt-project.org/wiki/QBS Everything what I hate about CMake does QBS better.
But the drawback is, it has no VS project generator.

User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Re: CMake 3.0.0

Post by Klaim »

FrameFever wrote:
Klaim wrote: I sincerely wish I could do that to help Ogre (among other things) but my time with CMake makes me think I still don't understand everything about it and it's highly frustrating (so I always feel like a noob).
...
Wish me good luck! *dive in build-system hell*
When you don't like this build system, why do you use it anyway?
It's the only one that actually does the whole work. It's also the one used by most of my dependencies. It's also evolving well.
Do you know QBS? http://qt-project.org/wiki/QBS Everything what I hate about CMake does QBS better.
But the drawback is, it has no VS project generator.
Major drawback for my game project at least (I desperately need the VS debugger for very specific reasons).
Also even if I have one project that I want to use QtCreator with instead of VS, it depends on other sub-projects (from the same group of projects) that MUST be totally independent from Qt techs (for various domain-specific reasons).
So it's not an option for my current projects. Might be good in other cases though.

I'm closely following the progress on several build systems like Premake, Waf, QBS, etc, so I'm totally aware of the pros and cons of the alternatives (which most of them I even tried in different projects).

User avatar
Kojack
OGRE Moderator
OGRE Moderator
Posts: 7153
Joined: Sun Jan 25, 2004 7:35 am
Location: Brisbane, Australia
x 519

Re: CMake 3.0.0

Post by Kojack »

Klaim wrote:I'm closely following the progress on several build systems like Premake, Waf, QBS, etc, so I'm totally aware of the pros and cons of the alternatives (which most of them I even tried in different projects).
I've started using Premake5 (the dev version) for my framework. I'm using it to build both Ogre 2.0 and Bullet.
There's some issues (the way it does include paths and names vc file filters) but it's scripts are easy and so far it's better than what I was using (ruby scripts that modify settings generated by ogre's cmake).
(No idea about other platforms, I'm only using it to generate vc2013 64 bit projects)

User avatar
Klaim
Old One
Posts: 2565
Joined: Sun Sep 11, 2005 1:04 am
Location: Paris, France
x 56
Contact:

Re: CMake 3.0.0

Post by Klaim »

Kojack wrote:
Klaim wrote:I'm closely following the progress on several build systems like Premake, Waf, QBS, etc, so I'm totally aware of the pros and cons of the alternatives (which most of them I even tried in different projects).
I've started using Premake5 (the dev version) for my framework. I'm using it to build both Ogre 2.0 and Bullet.
There's some issues (the way it does include paths and names vc file filters) but it's scripts are easy and so far it's better than what I was using (ruby scripts that modify settings generated by ogre's cmake).
(No idea about other platforms, I'm only using it to generate vc2013 64 bit projects)
I'm waiting for it to stabilize and check it on my target platforms before trying it. Also, I will still need compatibility with CMake because of most dependencies. In my case I can't rely on dependencies to be installed in the environement and the sources have to be provided with the project, so using CMake is far easier to be able to see all the dependencies and their sources.

Transporter
Minaton
Posts: 933
Joined: Mon Mar 05, 2012 11:37 am
Location: Germany
x 110

Re: CMake 3.0.0

Post by Transporter »

Klaim wrote:I'm waiting for it to stabilize and check it on my target platforms before trying it. Also, I will still need compatibility with CMake because of most dependencies. In my case I can't rely on dependencies to be installed in the environement and the sources have to be provided with the project, so using CMake is far easier to be able to see all the dependencies and their sources.
Yes, same here. The current cmake system is the most powerful method to get all dependencies to work.

Post Reply