[Dune] cmake build, how to specify non-standard libraries

Markus Blatt markus at dr-blatt.de
Tue Nov 25 11:50:10 CET 2014


Hi,


upfront: It is probably easier nd more portable to do this entirely in CMake:

find_package(Boost 1.55.0 COMPONENTS system)

target_link_libraries(target ${Boost_LIBRARIES})

I did some research and tests. If you really want to modify the linker
flags from cmake call then you can do this with CMAKE_EXE_LINKER_FLAGS:

cmake \
-DCMAKE_EXE_LINKER_FLAGS="-L$HOME/extlib/boost/1.55.0/gcc/4.8.1/lib \
-lboost_system" <source-dir>

Cheers,

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/attachments/20141125/dc8343c4/attachment.sig>


More information about the Dune mailing list