<div class="gmail_quote">On Thu, Mar 12, 2009 at 7:39 PM, Bart Janssens <span dir="ltr">&lt;<a href="mailto:bart.janssens@lid.kviv.be">bart.janssens@lid.kviv.be</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;">

Not sure if this ever came up, but I&#39;m struggling with FindBoost and<br>
the boost system library. The system library is required from boost<br>
1.35 onwards, but doesn&#39;t exist in earlier versions. Is there a way to<br>
make CMake only look for the system library if the boost version is<br>
greater than or equal to 1.35? I&#39;m using CMake 2.6.1.</blockquote><div><br>I&#39;ve never seen this come up before but you do have a good point about
the System library refactoring causing some people a bit of heartache
here.<br><br>I&#39;ve
logged a bug report for it here.  I&#39;m pretty sure the best fix would be
to get FindBoost to ignore the system component when it&#39;s detected a
version less than 1.35.  I&#39;ve attached a new FindBoost.cmake to the bug report which does this, if you could give it a shot?<br><br><a href="http://public.kitware.com/Bug/view.php?id=8734">http://public.kitware.com/Bug/view.php?id=8734</a><br>
<br><br><br><br>P.S.<br><br>A crappier workaround might be
to do something like this.  This probably will fail initially and the
user could toggle the option and I think it would start working on the
second configure... kinda sucky though.<br><br>OPTION(I_AM_USING_OLDER_BOOST &quot;Set to true if using Boost 1.35&quot; OFF)<br>IF(I_AM_USING_OLDER_BOOST)<br>   find_package(Boost 1.30 REQUIRED filesystem)<br>ELSE()<br>
   find_package(Boost 1.35 REQUIRED filesystem system)<br>ENDIF()<br></div></div><br>There might be other ways of faking out FindBoost as well by poking around with advanced cache variables it relies upon.<br><br>-- <br>Philip Lowman<br>