1
0
mirror of https://github.com/CLIUtils/CLI11.git synced 2025-05-07 23:33:52 +00:00

Boost Optional before 1.58 is too buggy to support

This commit is contained in:
Henry Schreiner 2018-04-18 18:10:57 -04:00
parent ef1aa10fdb
commit 2d6581a394
3 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,6 @@
### Version 1.5.3: Compiler compatibility
This version fixes older AppleClang compilers by removing the optimization for casting. The minimum version of Boost Optional supported has been clarified to be 1.58.
### Version 1.5.2: LICENSE in single header mode
This is a quick patch release that makes LICENSE part of the single header file, making it easier to include. Minor cleanup from codacy. No significant code changes from 1.5.1.

View File

@ -21,8 +21,11 @@
#endif
#if __has_include(<boost/optional.hpp>) && !defined(CLI11_BOOST_OPTIONAL)
#include <boost/version.hpp>
#if BOOST_VERSION >= 105800
#define CLI11_BOOST_OPTIONAL
#endif
#endif
#endif

View File

@ -72,7 +72,7 @@ file(WRITE "${PROJECT_BINARY_DIR}/CTestCustom.cmake"
)
# Add boost to test boost::optional if available
find_package(Boost 1.35)
find_package(Boost 1.58)
if(Boost_FOUND)
target_link_libraries(informational PUBLIC Boost::boost)
target_link_libraries(OptionalTest PUBLIC Boost::boost)