3 FIND_PACKAGE_HELPER(Boost boost/version.hpp QUIET)
\r
5 IF(BOOST_INCLUDE_DIR)
\r
6 IF(NOT BOOST_VERSION)
\r
7 PARSE_VERSION_OTHER(${BOOST_INCLUDE_DIR}/boost/version.hpp BOOST_VERSION)
\r
10 # Hack because patch is base 100 and minor version is base 1000
\r
11 CONVERT_NUMBER_VERSION(${BOOST_VERSION}0 1000 _VERSIONS)
\r
12 LIST(GET _VERSIONS 0 BOOST_VERSION_PATCH)
\r
13 LIST(GET _VERSIONS 1 BOOST_VERSION_MINOR)
\r
14 LIST(GET _VERSIONS 2 BOOST_VERSION_MAJOR)
\r
15 SET(BOOST_VERSION "${BOOST_VERSION_MAJOR}.${BOOST_VERSION_MINOR}.${BOOST_VERSION_PATCH}")
\r
21 MESSAGE(FATAL_ERROR "Unable to find Boost")
\r
24 FOREACH(COMPONENT ${MyBoost_FIND_COMPONENTS})
\r
25 SET(_NAME Boost${COMPONENT})
\r
26 STRING(TOUPPER ${_NAME} _UPNAME)
\r
28 SET(${_NAME}_FIND_REQUIRED ${MyBoost_FIND_REQUIRED})
\r
31 SET(_COMPILER "vc150")
\r
33 SET(_COMPILER "vc140")
\r
35 SET(_COMPILER "vc130")
\r
37 SET(_COMPILER "vc120")
\r
39 SET(_COMPILER "vc110")
\r
41 SET(_COMPILER "vc100")
\r
43 SET(_COMPILER "vc90")
\r
45 SET(_COMPILER "vc80")
\r
47 SET(_COMPILER "mingw")
\r
49 SET(_COMPILER "unknown")
\r
52 SET(_VERSION "${BOOST_VERSION_MAJOR}_${BOOST_VERSION_MINOR}")
\r
54 IF(DEFINED BOOST_DIR)
\r
55 SET(${_UPNAME}_DIR ${BOOST_DIR})
\r
58 FIND_PACKAGE_HELPER(${_NAME} boost/version.hpp
\r
59 RELEASE boost_${COMPONENT}-${_COMPILER}-mt-${_VERSION} boost_${COMPONENT}-mt boost_${COMPONENT}
\r
60 DEBUG boost_${COMPONENT}-${_COMPILER}-mt-gd-${_VERSION} boost_${COMPONENT}-mt-gd boost_${COMPONENT}-gd
\r
63 IF(${_UPNAME}_FOUND)
\r
64 LIST(APPEND BOOST_LIBRARIES ${${_UPNAME}_LIBRARIES})
\r
68 MESSAGE_VERSION_PACKAGE_HELPER(Boost ${BOOST_VERSION} ${BOOST_LIBRARIES})
\r