Merge branch 'master' of bitbucket.org:glavaux/cosmotool

This commit is contained in:
LAVAUX Guilhem 2020-04-28 22:34:57 +02:00
commit 02622a1285

View File

@ -247,17 +247,23 @@ if (INTERNAL_BOOST)
ELSE (INTERNAL_BOOST)
find_package(Boost 1.69 QUIET)
if (NOT Boost_FOUND)
cmessage(CWARNING "Boost >= 1.69 was not found")
else()
cmessage(STATUS "Boost has been found (version=${Boost_VERSION})")
endif()
if (Boost_VERSION)
if (${Boost_VERSION} VERSION_GREATER 1000)
math(EXPR TMP_MAJOR "${Boost_VERSION} / 100000")
math(EXPR TMP_MINOR "(${Boost_VERSION} - ${TMP_MAJOR} * 100000) / 100")
math(EXPR TMP_PATCHLEVEL "${Boost_VERSION} - ${TMP_MAJOR} * 100000 - ${TMP_MINOR} * 100")
set(Boost_VERSION ${TMP_MAJOR}.${TMP_MINOR}.${TMP_PATCHLEVEL})
ENDIF()
if (${Boost_VERSION} VERSION_GREATER_EQUAL 1.70.0)
set(Boost_DEP Boost::headers)
set(Boost_TARGET Boost::headers)
endif()
endif()
if (NOT Boost_FOUND)
cmessage(CWARNING "Boost >= 1.69 was not found")
else()
cmessage(STATUS "Boost has been found (version=${Boost_VERSION}), Boost_TARGET=${Boost_Target}")
endif()
endif (INTERNAL_BOOST)
mark_as_advanced(Boost_INCLUDE_DIRS Boost_LIBRARIES)