File tree Expand file tree Collapse file tree 2 files changed +16
-11
lines changed Expand file tree Collapse file tree 2 files changed +16
-11
lines changed Original file line number Diff line number Diff line change @@ -54,16 +54,19 @@ if(BOOST_JSON_IS_ROOT)
54
54
unset (CMAKE_FOLDER)
55
55
endif ()
56
56
57
- list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR} /pretty_printers" )
58
- find_package (BoostPrettyPrinters QUIET )
59
- if (BoostPrettyPrinters_FOUND)
60
- boost_pretty_printers_gdb_python_header(
61
- TARGET boost_json_regenerate_printers
62
- INPUT src/boost_json_gdb_printers.py
63
- OUTPUT include /boost/json/detail/gdb_printers.hpp
64
- HEADER_GUARD BOOST_JSON_DETAIL_GDB_PRINTERS_HPP
65
- NO_DISABLE_MACRO
66
- EXCLUDE_FROM_ALL )
57
+ if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.12.0" )
58
+ list (APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR} /pretty_printers" )
59
+ # Note: find_package(Python3) supported in cmake-3.12 onwards
60
+ find_package (BoostPrettyPrinters QUIET )
61
+ if (BoostPrettyPrinters_FOUND)
62
+ boost_pretty_printers_gdb_python_header(
63
+ TARGET boost_json_regenerate_printers
64
+ INPUT src/boost_json_gdb_printers.py
65
+ OUTPUT include /boost/json/detail/gdb_printers.hpp
66
+ HEADER_GUARD BOOST_JSON_DETAIL_GDB_PRINTERS_HPP
67
+ NO_DISABLE_MACRO
68
+ EXCLUDE_FROM_ALL )
69
+ endif ()
67
70
endif ()
68
71
69
72
function (boost_json_setup_properties target )
Original file line number Diff line number Diff line change @@ -61,7 +61,9 @@ target_compile_definitions(boost_json-no_exceptions PRIVATE
61
61
BOOST_JSON_NO_LIB=1
62
62
)
63
63
target_compile_options (boost_json-no_exceptions PRIVATE
64
- $<$<CXX_COMPILER_ID:GNU,Clang,AppleClang>:-fno-exceptions>
64
+ $<$<CXX_COMPILER_ID:GNU>:-fno-exceptions>
65
+ $<$<CXX_COMPILER_ID:Clang>:-fno-exceptions>
66
+ $<$<CXX_COMPILER_ID:AppleClang>:-fno-exceptions>
65
67
$<$<CXX_COMPILER_ID:MSVC >:/wd4530>
66
68
$<$<CXX_COMPILER_ID:MSVC >:/wd4577>
67
69
)
You can’t perform that action at this time.
0 commit comments