Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 13 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,16 +54,19 @@ if(BOOST_JSON_IS_ROOT)
unset(CMAKE_FOLDER)
endif()

list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/pretty_printers")
find_package(BoostPrettyPrinters QUIET)
if(BoostPrettyPrinters_FOUND)
boost_pretty_printers_gdb_python_header(
TARGET boost_json_regenerate_printers
INPUT src/boost_json_gdb_printers.py
OUTPUT include/boost/json/detail/gdb_printers.hpp
HEADER_GUARD BOOST_JSON_DETAIL_GDB_PRINTERS_HPP
NO_DISABLE_MACRO
EXCLUDE_FROM_ALL)
if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.12.0")
list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/pretty_printers")
# Note: find_package(Python3) supported in cmake-3.12 onwards
find_package(BoostPrettyPrinters QUIET)
if(BoostPrettyPrinters_FOUND)
boost_pretty_printers_gdb_python_header(
TARGET boost_json_regenerate_printers
INPUT src/boost_json_gdb_printers.py
OUTPUT include/boost/json/detail/gdb_printers.hpp
HEADER_GUARD BOOST_JSON_DETAIL_GDB_PRINTERS_HPP
NO_DISABLE_MACRO
EXCLUDE_FROM_ALL)
endif()
endif()

function(boost_json_setup_properties target)
Expand Down
4 changes: 3 additions & 1 deletion test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ target_compile_definitions(boost_json-no_exceptions PRIVATE
BOOST_JSON_NO_LIB=1
)
target_compile_options(boost_json-no_exceptions PRIVATE
$<$<CXX_COMPILER_ID:GNU,Clang,AppleClang>:-fno-exceptions>
$<$<CXX_COMPILER_ID:GNU>:-fno-exceptions>
$<$<CXX_COMPILER_ID:Clang>:-fno-exceptions>
$<$<CXX_COMPILER_ID:AppleClang>:-fno-exceptions>
$<$<CXX_COMPILER_ID:MSVC>:/wd4530>
$<$<CXX_COMPILER_ID:MSVC>:/wd4577>
)
Expand Down
Loading