[CMake] Linking Boost on Linux on 64bit host and 32bit target

Philip Lowman philip at yhbt.com
Fri Nov 5 07:09:47 EDT 2010


On Thu, Nov 4, 2010 at 12:31 PM, Michael Jackson <
mike.jackson at bluequartz.net> wrote:

> Clean out your build folder first.
> export BOOST_ROOT=/home/kknox/sdk/boost_1_44_0
> ==> that needs to be an actual "installation", a staged area will probably
> NOT work to find boost as FindBoost is looking for a very specific path
> within BOOST_ROOT and if that path is NOT found then it will probably fall
> back on the system paths.
>

FindBoost.cmake in CMake 2.8.3 supports a new option to prevent searching
the system paths.  You should enable it if you are 100% sure that you will
never want to find something outside of BOOST_ROOT, CMAKE_PREFIX_PATH, etc.
Boost_NO_SYSTEM_PATHS

There was a bug related to not finding Boost libraries in a staging area.  I
believe this works now.

Also, take a moment and set this new variable appropriately (nearly all
users will want it to be OFF)
Boost_USE_STATIC_RUNTIME

-- 
Philip Lowman
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20101105/14db0a11/attachment.htm>


More information about the CMake mailing list