<html><body><div style="font-family: times new roman, new york, times, serif; font-size: 12pt; color: #000000"><div><br></div><div><br></div><hr id="zwchr"><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><b>De: </b>"Roger Leigh" <rleigh@codelibre.net><br><b>À: </b>"Franck Houssen" <franck.houssen@inria.fr><br><b>Cc: </b>cmake@cmake.org<br><b>Envoyé: </b>Dimanche 7 Janvier 2018 18:14:04<br><b>Objet: </b>Re: [CMake] CMake: using dlopen<br><div><br></div><div><br></div><div style="font-size:100%;color:#000000" data-mce-style="font-size: 100%; color: #000000;"><div>-------- Original message --------</div><div>From: Franck Houssen <franck.houssen@inria.fr></div><div>Date: 07/01/2018 13:58 (GMT+00:00)</div><div>To: Roger Leigh <rleigh@codelibre.net></div><div>Cc: cmake@cmake.org</div><div>Subject: Re: [CMake] CMake: using dlopen</div><div><br></div></div>> OK, thanks. So, I go with: target_link_libraries(main PUBLIC ... ${CMAKE_DL_LIBS})<br><div><br></div>Use PRIVATE if it is not used in any headers--it's an internal implementation detail.</blockquote><div><br></div><div>Difference between PUBLIC/PRIVATE has never been clear to me (usually I always use PUBLIC).</div><div> main.cpp includes dlfcn.h and uses it: not sure to get what you meant (PRIVATE is for templates ? when a header include headers ?)<br></div><div><br></div><blockquote style="border-left:2px solid #1010FF;margin-left:5px;padding-left:5px;color:#000;font-weight:normal;font-style:normal;text-decoration:none;font-family:Helvetica,Arial,sans-serif;font-size:12pt;" data-mce-style="border-left: 2px solid #1010FF; margin-left: 5px; padding-left: 5px; color: #000; font-weight: normal; font-style: normal; text-decoration: none; font-family: Helvetica,Arial,sans-serif; font-size: 12pt;"><div><br></div><div>Regards,</div><div>Roger</div></blockquote><div><br></div></div></body></html>