[Dune-devel] [Dune-Commit] [Commit] dune-common - 826a38d: [m4] fix mixup when using autools/cmake 2.4 + an installed 2.3

Markus Blatt markus at dr-blatt.de
Sun Mar 15 15:47:51 CET 2015


I have not tested this, but:

On Sat, Mar 14, 2015 at 10:32:01PM +0100, Christian Engwer wrote:
> New commit, appeared at Sat Mar 14 22:32:01 2015 +0100
> as part of the following ref changes:
> 
>     branch refs/heads/master    updated from 662a4ff -> 826a38d
> 
> Browsable version: http://cgit.dune-project.org/repositories/dune-common/commit/?id=826a38d35b3b0f4e958a96124e637f2b7099eb0f
> 
> ======================================================================
> 
> commit 826a38d35b3b0f4e958a96124e637f2b7099eb0f
> Author: Christian Engwer <christi at dune-project.org>
> Date:   Sat Mar 14 22:29:06 2015 +0100
> 
>     [m4] fix mixup when using autools/cmake 2.4 + an installed 2.3
>     
>     Ich a module is not updated to cmake yet, we can have the situation, that the core modules
>     are built using cmake, but used by autotools. When trying to detect a dune library, we either
>     explicitly stated the /blablabla/libdunefoo.la file if the the dependency was built using autools,
>     or used the '-ldunefoo -L/blablabla/' options. This failed with very subtle errors if dune was
>     also installed globally, e.g. a 2.3 from your favorite distribution. We fix this now in the same
>     way as we fixed it for autotools. If the module is local, we explicitly state the lib...
>     either as .la or as .a.
> 
>  m4/dune.m4 | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> 
> 
> diff --git a/m4/dune.m4 b/m4/dune.m4
> index 46659e7..6ea6194 100644
> --- a/m4/dune.m4
> +++ b/m4/dune.m4
> @@ -383,8 +383,8 @@ AC_DEFUN([DUNE_CHECK_MODULES],[
>          AS_IF([test -f "$_DUNE_MODULE[]_LIBDIR[]/lib[]_dune_lib[].la"], [
>            # local modules is linked directly via the .la file
>            _dune_cm_LIBS="$_DUNE_MODULE[]_LIBDIR[]/lib[]_dune_lib[].la"],[
> -          # No libtool file. This indicates a module build with CMake. Fall back to direct linking
> -          _dune_cm_LIBS="-L$_DUNE_MODULE[]_LIBDIR[]/ -l[]_dune_lib[]"
> +          # No libtool file. This indicates a module build with CMake. Use the .a file
> +          _dune_cm_LIBS="$_DUNE_MODULE[]_LIBDIR[]/lib[]_dune_lib[].a"
>          ])
>        ])

What happens if one uses shared libraries and there is no *.la file?

Markus

-- 
Do you need more support with DUNE or HPC in general? 

Dr. Markus Blatt - HPC-Simulation-Software & Services http://www.dr-blatt.de
Hans-Bunte-Str. 8-10, 69123 Heidelberg, Germany
Tel.: +49 (0) 160 97590858
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <https://lists.dune-project.org/pipermail/dune-devel/attachments/20150315/60a39a71/attachment.sig>


More information about the Dune-devel mailing list