[Dune] Dune and CMake

Andreas Lauser andreas.lauser at iws.uni-stuttgart.de
Tue Dec 8 14:15:01 CET 2009


Hi,

CMake can be used in addition to the current build system, as it only adds a 
few files. In my opinion its main advantage is that the tools required to for 
the build reduce to CMake + make instead of 
m4+bash+perl+automake+autoconf+libtool+aclocal+C+make. 

As an additional bonus CMake is also able to generate VisualStudio and Eclipse 
projects instead of plain Makefiles, so it does not get in the way if someone 
wants to port DUNE to windows. The KDE project uses this feature quite 
extensively...

Also writing new tests for CMake is _much_ simpler than writing them for the 
autotools buildsystem, so even if there are some missing modules it would not 
take too much effort to write them. I guess most of the work required to use 
CMake as a full replacement for autotools in DUNE would be to adapt the 
dunecontrol script.

Regards
  Andreas

>thank you for your quick response.
>
>Currently, I do not think of having a replacement. More of 
>starting to work on it as an alternative and see how far 
>we can get. Of course, it will take a lot of time until it 
>can do everything the current build system can do.
>
>So far, we just included it for our module, and we can 
>build our tests with it. In comparison, I see two 
>advantages:
>- CMake is very fast. Configuring takes almost no time.
>- Out of source builts are standard.
>
>Since I am not really the expert, @Andreas L.: can you 
>maybe add something to this?
>
>Of course you are right that a replacement should be 
>better than the stuff it replaces. My question is just 
>intended to check for your interest to maybe get us 
>motivated getting started.
>
>Kind regards
>Bernd
>
>On Mon, 7 Dec 2009 19:41:37 +0100
>  Christian Engwer <christi at uni-hd.de> wrote:
>> Hi Bernd,
>> 
>>> for our Dune module Dumux, we alternatively can use 
>>>CMake 
>>> as build system (thanks to Andreas Lauser). Meanwhile, 
>>> some of us, including me, pretty much like using it.
>>> 
>>> We are definitely interested and might even have some 
>>> capabilities to also add this possibility to the Dune 
>>> core. This means to add some Makefile.am-like text 
>>>files. 
>>> The question is whether you would be interested in 
>>>having 
>>> that alternative, and whether it might even have a 
>>>chance 
>>> to be included into Dune by means of applying our 
>>>patches 
>>> from time to time.
>> 
>> I don't tink we must stick with the autotools, but a 
>>replacement will
>> have to provide all the current features. I don't know 
>>anything about
>> cmake. Perhaps you could tell a little bit more about 
>>what is working
>> and waht not. How much work it would be to port the 
>>current
>> buildsystem and so on. WOuld it perhaps solve some of 
>>the current -
>> hard to fix - buildsystem issues?
>> 
>> I'm not against changing it, but I don't want a half 
>>working
>> replacement.
>
-- 
Andreas Lauser
Lehrstuhl für Hydromechanik und Hydrosystemmodellierung
Universität Stuttgart - Institut für Wasserbau
Pfaffenwaldring 61
D-70569 Stuttgart
Tel: (+49) 0711/ 685-64719
Fax: (+49) 0711/ 685-60430
e-mail: andreas.lauser at iws.uni-stuttgart.de




More information about the Dune mailing list