<div style="line-height:1.7;color:#000000;font-size:14px;font-family:Arial"><div>In my cmake project, there are some subdirectories within it, and some of them have to build as completed </div><div>static or shared libraries.</div><div>1. The top project is executable </div><div>2. a subdirectory is a shared project, which also have some subdirectoy compile as static libraries which</div><div>   of course should ONLY link into their parent shared library</div>
<div>I add link options to linking the shared library produced by its subdirectory(which linked as a shared library), </div><div>but I found the all sub-static library with the shared library project(the subdirectory) also double linked into</div><div>the top executable project. Of course I only want to link the shared library. How to resolve such problem </div><div>for the top CMakeLists.txt?</div></div><br><br><span title="neteasefooter"><p> </p></span>