<div dir="ltr"><div dir="ltr"><br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Apr 11, 2019 at 1:35 AM Stéphane Ancelot <<a href="mailto:sancelot@numalliance.com">sancelot@numalliance.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-style:solid;border-left-color:rgb(204,204,204);padding-left:1ex">
  

    
  
  <div bgcolor="#FFFFFF">
    <p>Hi,</p>
    <p>are there any specific Cmake configurations to setup in projects
      when using fetchcontent.</p>
    <p>I am able to fetch and build a library but not able to link and
      include files of this library in another projects.</p>
    <p>include(FetchContent)<br>
      <br>
      FetchContent_Declare(<br>
        jconcpp<br>
        GIT_REPOSITORY <a class="gmail-m_-7671476006035390538moz-txt-link-freetext" href="https://github.com/joncol/jcon-cpp.git" target="_blank">https://github.com/joncol/jcon-cpp.git</a><br>
      )<br>
      <br>
      FetchContent_Populate(jconcpp)<br>
      add_subdirectory(${jconcpp_SOURCE_DIR} ${jconcpp_BINARY_DIR})</p></div></blockquote><div><br></div><div>Can you provide a complete minimal example which shows the problem? The snippet above should bring jsoncpp into your main build, but without seeing how you are trying to link to it's targets, it is hard to tell what the problem could be.</div><div> </div></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr">Craig Scott<br><div>Melbourne, Australia</div><div><a href="https://crascit.com" target="_blank">https://crascit.com</a><br></div><div><br></div><div>Get the hand-book for every CMake user: <a href="https://crascit.com/professional-cmake/" target="_blank">Professional CMake: A Practical Guide</a><br></div></div></div></div></div></div></div></div></div></div></div></div></div></div>