[CMake] Boost components depending on Boost version

Esben Mose Hansen kde at mosehansen.dk
Tue Oct 14 03:30:46 EDT 2008


On Sunday 12 October 2008 20:58:07 0xd34df00d wrote:
> Hi there!
>
> How could one find and link to boost.system only if boost's version is
> greater or equal 1.35?

FIND_PACKAGE( Boost 1.35 COMPONENTS system)

after that, you have to check BOOST_FOUND and act accordingly.

I think you need cmake 2.5+ for this to work.

-- 
kind regards, Esben


More information about the CMake mailing list