[Dune] Building DUNE with Cmake: SuperLU - fixed

lriedel at iup.uni-heidelberg.de lriedel at iup.uni-heidelberg.de
Thu Jul 23 14:00:40 CEST 2015


Hello Christoph,

I just got the problem fixed. Silly Me messed up some file names when
creating a new Dune project for testing.
It simply works when adding the "add_dune_superlu_flags(...)" correctly.

Cheers,
Lukas

> Hello Christoph,
>
> As you might have guessed I did not find this document before. Thank you!
> However, adding the appropriate commands does not fix my problem.
>
> In the CMakeLists.txt file in the <myproject>/src directory I added a line
> for the flags:
>
> add_executable("<myproject>" <myproject>.cc)
> add_dune_superlu_flags("myproject")
> target_link_dune_default_libraries("myproject")
>
> and into the cmake/modules directory I copied the macros regarding SuperLU
> (FindSuperLU.cmake and AddSuperLUFlags.cmake) of the dune-istl package -
> just in case - and added them to the modules list. The
> <myproject>Macros.cmake file there reads
>
> find_package(ParMETIS REQUIRED)
> include(AddParMETISFlags)
> find_package(SuperLU REQUIRED)
> include(AddSuperLUFlags)
>
> However, the build system does mention neither SuperLU nor ParMETIS as
> required, but as optional.
> It still performs the necessary tests successfully:
>
> -- Performing Test SUPERLU_MIN_VERSION_4_3 - Success
> -- Found SuperLU: /Applications/DUNE/build/SuperLU_4.3/SRC
>
> Still, the Linear Solver cannot be found:
>
>  error: 'ISTLBackend_SEQ_SuperLU' in namespace 'Dune::PDELab' does not
> name a type
>    typedef Dune::PDELab::ISTLBackend_SEQ_SuperLU LS;
>
> My CMake Flags:
>     -DCMAKE_BUILD_TYPE=none
>     -DCMAKE_DISABLE_FIND_PACKAGE_MPI=TRUE
>     -DUSE_SUPERLU=ON
>     -DMPI_ROOT=$INSTALLDIR/OpenMpi
>     -DUG_ROOT=$INSTALLDIR/UG
>     -DSUPERLU_ROOT=$INSTALLDIR/SuperLU_4.3
>     -DBLAS_ROOT=$INSTALLDIR/OpenBLAS/lib/libopenblas.a
>     -DMETIS_ROOT=$INSTALLDIR/METIS
>     -DPARMETIS_ROOT=$INSTALLDIR/METIS
>     <...>
>
> Cheers,
> Lukas
>
>
>> Hi Lukas,
>> have a look at Question 5 of our CMake FAQ:
>> http://www.dune-project.org/doc/buildsystem/cmakefaq.pdf
>>
>> Bye
>> Christoph
>>
>> --
>> Je n'ai rien contre les étrangers, quelques uns de mes
>> meilleurs amis
>> sont des étrangers. Mais ces étrangers là ne sont pas de chez
>> nous!
>> [Agecanonix, Astérix - Le cadeau de César]
>>
>
>






More information about the Dune mailing list