<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;"><b>De: </b>"Rainer Poisel" <rainer.poisel@gmail.com><br><b>À: </b>"J Decker" <d3ck0r@gmail.com><br><b>Cc: </b>"Franck Houssen" <franck.houssen@inria.fr>, cmake@cmake.org<br><b>Envoyé: </b>Samedi 6 Janvier 2018 17:30:53<br><b>Objet: </b>Re: [CMake] CMake: using dlopen<br><div><br></div><div dir="auto">Hi,<div dir="auto"><br></div><div dir="auto">I would use ${CMAKE_DL_LIBS} in target_link_libraries:</div><div dir="auto"><br></div><div dir="auto">  * <a href="https://cmake.org/cmake/help/v3.0/variable/CMAKE_DL_LIBS.html" target="_blank"><a>https://cmake.org/cmake/help/v3.0/variable/CMAKE_DL_LIBS.html</a></a><br data-mce-bogus="1"></div></div></blockquote><div><br></div><div>But here again, who defined ${CMAKE_DL_LIBS}: I don't see it when I run "cmake -LA ."<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;"><div dir="auto"><div dir="auto"><br data-mce-bogus="1"></div><div dir="auto"><br></div><div dir="auto">Regards,</div><div dir="auto">  Rainer</div><br><div class="gmail_extra" dir="auto"><br><div class="gmail_quote">On Jan 6, 2018 16:19, "J Decker" <<a href="mailto:d3ck0r@gmail.com" target="_blank">d3ck0r@gmail.com</a>> wrote:<br><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">probably just need target_link_libraries( <target> dl ) </div><div class="gmail_extra"><br><div class="gmail_quote"><div class="elided-text">On Sat, Jan 6, 2018 at 6:34 AM, Franck Houssen <span dir="ltr"><<a href="mailto:franck.houssen@inria.fr" target="_blank">franck.houssen@inria.fr</a>></span> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="elided-text"><div><div style="font-family:times new roman,new york,times,serif;font-size:12pt;color:#000000"><div>Hello,<br></div><div><br></div><div>I have an executable that needs dlopen.<br></div><div><br></div><div>Googled this a bit: seems (surprisingly) there is no FindDLUtils ?!.. Correct ? If so, why is this ?<br></div><div>My understanding is that I need to go:</div><div>~BUILD> cmake -DCMAKE_LD_LIBS="-ldl -L/path/to/dl" ..<br></div><div>which is, basically, telling to CMake where dl is (although this is the job of a build system, no ?!)</div><div><br></div><div> Did I understand correctly ? Did I miss something ?<span class="m_7770070994680797492HOEnZb"><span data-mce-style="color: #888888;" style="color: #888888;"><br></span></span></div><span class="m_7770070994680797492HOEnZb"><span data-mce-style="color: #888888;" style="color: #888888;"><div><br></div><div>Franck<br></div></span></span></div></div><br></div>--<br><br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br><br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br><br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br><br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/training.html</a><br><br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br><br>
Follow this link to subscribe/unsubscribe:<br><a href="https://cmake.org/mailman/listinfo/cmake" rel="noreferrer" target="_blank">https://cmake.org/mailman/listinfo/cmake</a><br><br></blockquote></div><br></div><br>--<br><br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br><br>
Please keep messages on-topic and check the CMake FAQ at: <a href="http://www.cmake.org/Wiki/CMake_FAQ" rel="noreferrer" target="_blank">http://www.cmake.org/Wiki/CMake_FAQ</a><br><br>
Kitware offers various services to support the CMake community. For more information on each offering, please visit:<br><br>
CMake Support: <a href="http://cmake.org/cmake/help/support.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/support.html</a><br>
CMake Consulting: <a href="http://cmake.org/cmake/help/consulting.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/consulting.html</a><br>
CMake Training Courses: <a href="http://cmake.org/cmake/help/training.html" rel="noreferrer" target="_blank">http://cmake.org/cmake/help/training.html</a><br><br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br><br>
Follow this link to subscribe/unsubscribe:<br><a href="https://cmake.org/mailman/listinfo/cmake" rel="noreferrer" target="_blank">https://cmake.org/mailman/listinfo/cmake</a><br><br></blockquote></div><br></div></div></blockquote><div><br></div></div></body></html>