diff --git a/CMakeLists.txt b/CMakeLists.txt index c4c7aa9990..42dc4f0a63 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -340,7 +340,6 @@ add_zeek_dynamic_plugin_build_interface_include_directories( ${PROJECT_SOURCE_DIR}/auxil/binpac/lib ${PROJECT_SOURCE_DIR}/auxil/broker/libbroker ${PROJECT_SOURCE_DIR}/auxil/paraglob/include - ${PROJECT_SOURCE_DIR}/auxil/rapidjson/include ${PROJECT_SOURCE_DIR}/auxil/prometheus-cpp/core/include ${CMAKE_BINARY_DIR}/src ${CMAKE_BINARY_DIR}/src/include @@ -348,10 +347,6 @@ add_zeek_dynamic_plugin_build_interface_include_directories( ${CMAKE_BINARY_DIR}/auxil/broker/libbroker ${CMAKE_BINARY_DIR}/auxil/prometheus-cpp/core/include) -# threading/formatters/JSON.h includes rapidjson headers and may be used -# by external plugins, extend the include path. -target_include_directories(zeek_dynamic_plugin_base SYSTEM - INTERFACE $) target_include_directories( zeek_dynamic_plugin_base SYSTEM INTERFACE $) @@ -1010,9 +1005,6 @@ include(BuiltInSpicyAnalyzer) include_directories(BEFORE ${PCAP_INCLUDE_DIR} ${BIND_INCLUDE_DIR} ${BinPAC_INCLUDE_DIR} ${ZLIB_INCLUDE_DIR} ${JEMALLOC_INCLUDE_DIR}) -install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/auxil/rapidjson/include/rapidjson - DESTINATION include/zeek/3rdparty/rapidjson/include) - install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/auxil/filesystem/include/ghc DESTINATION include/zeek/3rdparty/) diff --git a/src/threading/formatters/JSON.cc b/src/threading/formatters/JSON.cc index 3231adfead..08a2c2a703 100644 --- a/src/threading/formatters/JSON.cc +++ b/src/threading/formatters/JSON.cc @@ -8,6 +8,8 @@ #define __STDC_LIMIT_MACROS #endif +#define RAPIDJSON_HAS_STDSTRING 1 + #include #include #include @@ -20,12 +22,6 @@ namespace zeek::threading::formatter { -// For deprecated NullDoubleWriter -JSON::NullDoubleWriter::NullDoubleWriter(rapidjson::StringBuffer& stream) - : writer(std::make_unique(stream)) {} - -bool JSON::NullDoubleWriter::Double(double d) { return writer->Double(d); } - JSON::JSON(MsgThread* t, TimeFormat tf, bool arg_include_unset_fields) : Formatter(t), timestamps(tf), include_unset_fields(arg_include_unset_fields) {} diff --git a/src/threading/formatters/JSON.h b/src/threading/formatters/JSON.h index d800ae986a..44dd78d198 100644 --- a/src/threading/formatters/JSON.h +++ b/src/threading/formatters/JSON.h @@ -4,12 +4,6 @@ #include -#define RAPIDJSON_HAS_STDSTRING 1 -// Remove in v7.1 when removing NullDoubleWriter below and also remove -// rapidjson include tweaks from CMake's dynamic_plugin_base target. -#include -#include - #include "zeek/threading/Formatter.h" namespace zeek::json::detail { @@ -39,16 +33,6 @@ public: Value* ParseValue(const std::string& s, const std::string& name, TypeTag type, TypeTag subtype = TYPE_ERROR) const override; - class NullDoubleWriter : public rapidjson::Writer { - public: - [[deprecated("Remove in v7.1 - This is an implementation detail.")]] NullDoubleWriter( - rapidjson::StringBuffer& stream); - bool Double(double d); - - private: - std::unique_ptr writer; - }; - private: void BuildJSON(zeek::json::detail::NullDoubleWriter& writer, Value* val, const std::string& name = "") const;