diff options
Diffstat (limited to 'Utilities/cmcppdap')
-rw-r--r-- | Utilities/cmcppdap/CMakeLists.txt | 37 | ||||
-rw-r--r-- | Utilities/cmcppdap/NOTICE | 5 | ||||
-rw-r--r-- | Utilities/cmcppdap/src/jsoncpp_json_serializer.cpp | 2 | ||||
-rw-r--r-- | Utilities/cmcppdap/src/jsoncpp_json_serializer.h | 2 |
4 files changed, 44 insertions, 2 deletions
diff --git a/Utilities/cmcppdap/CMakeLists.txt b/Utilities/cmcppdap/CMakeLists.txt new file mode 100644 index 0000000..39f72a2 --- /dev/null +++ b/Utilities/cmcppdap/CMakeLists.txt @@ -0,0 +1,37 @@ +# Disable warnings to avoid changing 3rd party code. +if(CMAKE_CXX_COMPILER_ID MATCHES + "^(GNU|LCC|Clang|AppleClang|IBMClang|XLClang|XL|VisualAge|SunPro|HP|Intel|IntelLLVM|NVHPC)$") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w") +elseif(CMAKE_CXX_COMPILER_ID STREQUAL "PathScale") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -woffall") +endif() + +add_library(cmcppdap STATIC + src/content_stream.cpp + src/io.cpp + src/jsoncpp_json_serializer.cpp + src/network.cpp + src/null_json_serializer.cpp + src/protocol_events.cpp + src/protocol_requests.cpp + src/protocol_response.cpp + src/protocol_types.cpp + src/session.cpp + src/socket.cpp + src/typeinfo.cpp + src/typeof.cpp +) + +target_compile_definitions(cmcppdap PRIVATE CPPDAP_JSON_JSONCPP=1) +target_include_directories(cmcppdap PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/include) +set_property(TARGET cmcppdap PROPERTY CXX_CLANG_TIDY "") +set_property(TARGET cmcppdap PROPERTY CXX_INCLUDE_WHAT_YOU_USE "") + +target_link_libraries(cmcppdap PRIVATE JsonCpp::JsonCpp) +if(WIN32) + target_link_libraries(cmcppdap PRIVATE ws2_32) +elseif(NOT APPLE) + target_link_libraries(cmcppdap PRIVATE Threads::Threads) +endif() + +install(FILES NOTICE DESTINATION ${CMAKE_DOC_DIR}/cmcppdap) diff --git a/Utilities/cmcppdap/NOTICE b/Utilities/cmcppdap/NOTICE new file mode 100644 index 0000000..5ad206c --- /dev/null +++ b/Utilities/cmcppdap/NOTICE @@ -0,0 +1,5 @@ +'cppdap' is a C++11 library implementation of the Debug Adapter Protocol. +Version as of 2023-01-06 +Copyright Google LLC + +This product includes software developed at Google. diff --git a/Utilities/cmcppdap/src/jsoncpp_json_serializer.cpp b/Utilities/cmcppdap/src/jsoncpp_json_serializer.cpp index 954b0e5..0d037a9 100644 --- a/Utilities/cmcppdap/src/jsoncpp_json_serializer.cpp +++ b/Utilities/cmcppdap/src/jsoncpp_json_serializer.cpp @@ -16,7 +16,7 @@ #include "null_json_serializer.h" -#include <json/json.h> +#include <cm3p/json/json.h> #include <cstdlib> #include <memory> diff --git a/Utilities/cmcppdap/src/jsoncpp_json_serializer.h b/Utilities/cmcppdap/src/jsoncpp_json_serializer.h index 6bdf6a4..93c510b 100644 --- a/Utilities/cmcppdap/src/jsoncpp_json_serializer.h +++ b/Utilities/cmcppdap/src/jsoncpp_json_serializer.h @@ -19,7 +19,7 @@ #include "dap/serialization.h" #include "dap/types.h" -#include <json/forwards.h> +#include <cm3p/json/forwards.h> namespace dap { namespace json { |