[Dune] using cmake to build your dune module

Christian Engwer christi at uni-hd.de
Tue Dec 7 16:14:18 CET 2010


Hi,

I have no clue about CMake, but the points you raised are all possible
using the current buildsystem.

> 1.) Allow Dune modules to be located anywhere in the filesystem. Use
> something like FIND_PACKAGE(Dune) inside the modules CMakeLists.txt
> file to fetch all necessary build options from Dune. This would
> external projects to integrate their Dune-Code into their
> source-code layout.

you just have to specify the DUNE_CONTROL_PATH to allow searcing in
other places. I further doubt that CMake can find your packages
without further hints.

> 2.) Allow out-of-source (aka shadow-builds) for Dune modules. I
> think it would be nice to keep the source tree clean and allow for
> separate Debug/Release builds, for example.

automake supports this aswell. The problem was that until recently it
was not possible to use out-of-source builds via dunecontrol. I
implemented this about a year ago.

I think the main advantage of CMake would be, that you can use DUNE
with IDEs like MS VisualStudio. If this is worth the effort, must be
decided by those, implementing the changes.

Christian




More information about the Dune mailing list