[Dune] Creating new modules

Oliver Sander sander at mi.fu-berlin.de
Tue Aug 21 15:04:12 CEST 2007


Hi Bernd!
What you describe is a known deficiency of the Dune buildsystem.
In fact it is entry 230 in our bugtracker.

If you just want headers from your Mod1 the quickest way is
to add an extra -I to the CPP_FLAGS in the Makefile.am of
Mod2 and thus hardcode the path of Mod1 there (not nice,
but easy).  If you want to link to Mod1 or if you just want to
to it right you have to modify dune.m4 and dunecontrol.
That is pretty straightforward.  However in order to not
screw up your build system you have to do that with the
svn version instead of the tarballs because you need to
call autogen.sh before being able to configure.

I hope this helps.  I'll set up the bug's priority as this really
is important.

--
Oliver

Bernd Flemisch wrote:

>Dear Dune developers,
>
>I successfully created a Dune module Mod1 with the duneproject script.
>The module itself works fine. Now, I want to create a new module Mod2
>depending on Mod1. Unfortunately, duneproject is not able to recognize
>that Mod1 exists and configuring Mod2 terminates with "error: Unknown
>module Mod1".
>
>The reason is obviously that in dune-common the names of the available
>modules are hardcoded,  in the files "configure", "dunecontrol",
>"dune_all.m4", and "dune.m4". Changing configure and dunecontrol is
>fine, but has no effect. As soon as one tries to adjust the m4-files,
>one runs into a big mess of autoconf/automake... errors, since, e.g.,
>LIBTOOL, BUILD_DOCS, and WML is not properly configured,
>DUNE_MINIMAL_DEBUG_LEVEL is not set, and so on. I was not able to work
>through this.
>
>In fact, I only want to include Mod1-header files into Mod2 by #include
><dune/...>. Do you see a way to achieve this without having to heavily
>manipulate dune-common?
>
>Best wishes
>Bernd
>
>  
>


-- 
************************************************************************
* Oliver Sander                ** email: sander at mi.fu-berlin.de        *
* Freie Universität Berlin     ** phone: + 49 (30) 838 75217           *
* Institut für Mathematik II   ** URL  : page.mi.fu-berlin.de/~sander  *
* Arnimallee 6                 ** -------------------------------------*
* 14195 Berlin, Germany        ** Member of MATHEON (www.matheon.de)   *
************************************************************************





More information about the Dune mailing list