<div class="gmail_quote">On Sun, May 17, 2009 at 2:35 PM, Robert Dailey <span dir="ltr">&lt;<a href="mailto:rcdailey@gmail.com">rcdailey@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="gmail_quote"><div><div></div><div class="h5">On Sun, May 17, 2009 at 12:16 PM, Philip Lowman <span dir="ltr">&lt;<a href="mailto:philip@yhbt.com" target="_blank">philip@yhbt.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">

<div class="gmail_quote"><div><div></div><div>On Sun, May 17, 2009 at 12:26 AM, Robert Dailey <span dir="ltr">&lt;<a href="mailto:rcdailey@gmail.com" target="_blank">rcdailey@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<div><br></div><div>I have built Boost 1.39 on Windows with static libraries, and they are named like so:</div><div><br></div><div>libboost_filesystem-mt.lib</div><div><br></div><div>When I try to do this:</div><div><br>



</div><div>find_package( Boost REQUIRED COMPONENTS filesystem )</div><div><br></div><div>I get an error saying it could not find boost_filesystem. If I rename the above library and remove the &#39;lib&#39; prefix, so it is just &quot;boost_filesystem-mt.lib&quot;, it finds it. Does the FindBoost.cmake module not support the lib prefix on Windows? This might be an inconsistency on Boost&#39;s part.</div>


</blockquote></div></div><div><br>Have you set(Boost_USE_STATIC_LIBS ON)?<br><br>This might be related to a post a while back which never was fully resolved involving FindBoost and static libs / dynamic stdlib vs. static libs / static stdlib.<br>


<br>Also, which version of FindBoost are you using?</div></div></blockquote><div><br></div></div></div><div>I&#39;m using the one packaged with CMake 2.6.4. Normally, the FindXXX modules will provide any configurable options as variables in the cache. However, in this case, it seems like the FindBoost module checks for Boost_USE_STATIC_LIBS, but does not make it immediately visible in the cache (i.e. the user has to set it themselves). </div>

</div>
</blockquote></div><br>I think it&#39;s probably best to leave it up to individual projects if they would like to expose Boost_USE_STATIC_LIBS to their cache.  You can of course do so simply by writing<br><br>option(Boost_USE_STATIC_LIBS &quot;Use boost static libraries&quot; ON)<br>
   prior to <br>find_package(Boost...)<br clear="all"><br>Until recently (i.e. the unset(...CACHE) command) it was not possible for user code to remove variables from the cache.  Generally I think this has yielded a conservative policy of module writers not adding options to the cache.<br>
<br>-- <br>Philip Lowman<br>