[Dune] cmake docu ?

Benedikt Oswald benedikt.oswald at lspr.ch
Fri Nov 21 18:40:42 CET 2014


Dear Markus,

thanks very much for the help with the libs and also for the hint to the
conversion script.
We might well use it!

Greetings, Benedikt

Am 21/11/14 um 18:29 schrieb Markus Blatt:
> BTW there is a handy script that can assist when converting a module
> from autotools to CMake, see dune-common/bin/am2cmake.py.
>
> It will parse your Makefile.am files and create CMakeLists.txt from
> it. You might want to clean them up manually afterwards.
>
> Markus
>
> On Fri, Nov 21, 2014 at 05:39:52PM +0100, Benedikt Oswald wrote:
>> Dear Dune,
>>
>> thanks for the support with the cmake based build system!
>>
>> I have progressed in migrating to the cmake based build system,
>> but I experience a linker problem that I dare present, cf. below.
>>
>> in my CMakeList.txt file I say:
>>
>> link_libraries(${DUNE_Boost_LIBRARIES})
>> include_directories(${Boost_INCLUDE_DIR})
>> add_definitions(-DENABLE_BOOST)
>>
>> add_executable(vulcain vulcain.cc)
>> target_link_libraries("vulcain")
>> add_dune_mpi_flags(vulcain)
>>
>>
>> Could you suggest if this is wrong/incomplete ?
>>
>> Thanks & greetings,
>> Benedikt
>>
>> PS: I understand that Dune will swtich to cmake as the default build system
>> over this weekend, in fact I find this very courageous...
>>
>>
>>
>> =========================
>>
>> Linking CXX executable vulcain
>> Undefined symbols for architecture x86_64:
>>   "Dune::dverb", referenced from:
>>       Dune::MPIHelper::MPIHelper(int&, char**&) in vulcain.cc.o
>>       Dune::MPIHelper::~MPIHelper() in vulcain.cc.o
>> ld: symbol(s) not found for architecture x86_64
>> collect2: error: ld returned 1 exit status
>>
>>
>>
>>
>>
>>
>>
>> Am 21/11/14 um 16:11 schrieb Markus Blatt:
>>> Hi,
>>>
>>> On Fri, Nov 21, 2014 at 03:31:01PM +0100, Benedikt Oswald wrote:
>>>> I build on Mac OS X currently, where cmake quite persistently chooses
>>>> the Apple clang compilers
>>>> as c an c++ compilers but then chooses the mpicxx, that I installed. It
>>>> results in something like:
>>>>
>>> If you are using dunecontrol, then you specify the compiler the usual
>>> way, e.g. in an opts-file via the CXXFLAGS. These are then translated
>>> to CMake syntax for you:
>>>
>>> CONFIGURE_FLAGS="CXX=g++-4.4 CC=gcc-4.4"
>>>
>>> If you are using CMake without dunecontrol than you specify them as
>>> cmake -DCMAKE_CXX_COMPILER:FILEPATH=/usr/bin/g++-4.4
>>> -DCMAKE_C_COMPILER:FILEPATH=/usr/bin/g++-4.4
>>>
>>> You can also just edit the file CMakeCache.txt in your build directory
>>> and rerung cmake there using "cmake ."
>>>
>>> Markus
>>>
>>>
>>>
>>> _______________________________________________
>>> Dune mailing list
>>> Dune at dune-project.org
>>> http://lists.dune-project.org/mailman/listinfo/dune
>
>
>> _______________________________________________
>> Dune mailing list
>> Dune at dune-project.org
>> http://lists.dune-project.org/mailman/listinfo/dune
>
>
>
> _______________________________________________
> Dune mailing list
> Dune at dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune

-- 
------------------------------------------------------------------------------------------------
Dr. sc. techn. Benedikt Oswald - first engineer - LSPR AG - phone - +41 43 366 90 74
Technoparkstrasse 1, CH-8005 Zürich, benedikt.oswald at lspr.ch - labor vincit omnia improbus
------------------------------------------------------------------------------------------------


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 882 bytes
Desc: OpenPGP digital signature
URL: <https://lists.dune-project.org/pipermail/dune/attachments/20141121/8d68f2ad/attachment.sig>


More information about the Dune mailing list