<div dir="ltr"><br><br><div class="gmail_quote"><div dir="ltr">Le ven. 31 août 2018 à 15:59, Stéphane Ancelot <<a href="mailto:sancelot@numalliance.com">sancelot@numalliance.com</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
  
    
  
  <div bgcolor="#FFFFFF">
    <p>I ended with :</p>
    <p>add_custom_target(combined ALL<br>
         COMMAND ${CMAKE_AR} rc libcombined.a $<TARGET_<a class="gmail-m_-4819724172989200321moz-txt-link-freetext">FILE:lib1</a>>
      $<TARGET_<a class="gmail-m_-4819724172989200321moz-txt-link-freetext">FILE:lib2</a>>) <br></p></div></blockquote><div><br></div><div>Quick & dirty :-)<br></div><div>There is the "thin" option of ar as well: <a href="https://stackoverflow.com/questions/3821916/how-to-merge-two-ar-static-libraries-into-one">https://stackoverflow.com/questions/3821916/how-to-merge-two-ar-static-libraries-into-one</a></div><div>if you know the content of lib1 and lib2 don't have name clash.</div><div><br></div><div>However libcombined.a is not a proper library target for CMake now.<br></div><div><br></div><div>And by the way does this work on Window too ? Or may be you don't care ?</div><div><br></div><div><br></div></div><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div>Eric<br></div></div></div></div></div></div>