# HG changeset patch # User Sebastien Jodogne # Date 1559804666 -7200 # Node ID 18cd4951fccc8c3e13425a4e413595adac4f0860 # Parent a48d652f15001c775c36bf21b47c2b3a6b684de8 fix diff -r a48d652f1500 -r 18cd4951fccc Plugins/Samples/Common/OrthancPluginCppWrapper.cpp --- a/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Wed Jun 05 17:17:48 2019 +0200 +++ b/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp Thu Jun 06 09:04:26 2019 +0200 @@ -2058,6 +2058,7 @@ +#if HAS_ORTHANC_PLUGIN_HTTP_CLIENT == 1 #if HAS_ORTHANC_PLUGIN_HTTP_CHUNKED_BODY == 1 class HttpClient::ChunkedBody : public boost::noncopyable { @@ -2271,4 +2272,5 @@ ORTHANC_PLUGINS_THROW_PLUGIN_ERROR_CODE(error); } } +#endif /* HAS_ORTHANC_PLUGIN_HTTP_CLIENT == 1 */ } diff -r a48d652f1500 -r 18cd4951fccc Plugins/Samples/Common/OrthancPluginCppWrapper.h --- a/Plugins/Samples/Common/OrthancPluginCppWrapper.h Wed Jun 05 17:17:48 2019 +0200 +++ b/Plugins/Samples/Common/OrthancPluginCppWrapper.h Thu Jun 06 09:04:26 2019 +0200 @@ -85,6 +85,12 @@ # define HAS_ORTHANC_PLUGIN_METRICS 0 #endif +#if ORTHANC_PLUGINS_VERSION_IS_ABOVE(1, 1, 0) +# define HAS_ORTHANC_PLUGIN_HTTP_CLIENT 1 +#else +# define HAS_ORTHANC_PLUGIN_HTTP_CLIENT 0 +#endif + #if ORTHANC_PLUGINS_VERSION_IS_ABOVE(1, 5, 7) # define HAS_ORTHANC_PLUGIN_HTTP_CHUNKED_BODY 1 #else @@ -779,6 +785,7 @@ #endif +#if HAS_ORTHANC_PLUGIN_HTTP_CLIENT == 1 class HttpClient : public boost::noncopyable { public: @@ -893,4 +900,5 @@ void Execute(); }; +#endif }