# HG changeset patch # User Sebastien Jodogne # Date 1594046310 -7200 # Node ID 8ada1b66919477eefc27fc07b1ac780299ae323a # Parent 9bdfa76c892357a4d28988f98f19c57a49505981 replacing deprecated std::auto_ptr by std::unique_ptr diff -r 9bdfa76c8923 -r 8ada1b669194 Plugin/AuthorizationParserBase.h --- a/Plugin/AuthorizationParserBase.h Wed Jul 01 16:10:12 2020 +0200 +++ b/Plugin/AuthorizationParserBase.h Mon Jul 06 16:38:30 2020 +0200 @@ -21,12 +21,14 @@ #include "IAuthorizationParser.h" #include "ResourceHierarchyCache.h" +#include // For std::unique_ptr<> + namespace OrthancPlugins { class AuthorizationParserBase : public IAuthorizationParser { private: - std::auto_ptr resourceHierarchy_; + std::unique_ptr resourceHierarchy_; void AddResourceInternal(AccessedResources& target, Orthanc::ResourceType level, diff -r 9bdfa76c8923 -r 8ada1b669194 Plugin/CachedAuthorizationService.h --- a/Plugin/CachedAuthorizationService.h Wed Jul 01 16:10:12 2020 +0200 +++ b/Plugin/CachedAuthorizationService.h Mon Jul 06 16:38:30 2020 +0200 @@ -21,6 +21,8 @@ #include "IAuthorizationService.h" #include "ICacheFactory.h" +#include // For std::unique_ptr<> + #include namespace OrthancPlugins @@ -31,8 +33,8 @@ class CachedAuthorizationService : public IAuthorizationService { private: - std::auto_ptr decorated_; - std::auto_ptr cache_; + std::unique_ptr decorated_; + std::unique_ptr cache_; std::string ComputeKey(OrthancPluginHttpMethod method, const AccessedResource& access, diff -r 9bdfa76c8923 -r 8ada1b669194 Plugin/Plugin.cpp --- a/Plugin/Plugin.cpp Wed Jul 01 16:10:12 2020 +0200 +++ b/Plugin/Plugin.cpp Mon Jul 06 16:38:30 2020 +0200 @@ -24,13 +24,14 @@ #include "../Resources/Orthanc/Plugins/OrthancPluginCppWrapper.h" +#include // For std::unique_ptr<> #include #include // Configuration of the authorization plugin -static std::auto_ptr authorizationParser_; -static std::auto_ptr authorizationService_; +static std::unique_ptr authorizationParser_; +static std::unique_ptr authorizationService_; static std::set uncheckedResources_; static std::list uncheckedFolders_; static std::list tokens_; diff -r 9bdfa76c8923 -r 8ada1b669194 Plugin/ResourceHierarchyCache.h --- a/Plugin/ResourceHierarchyCache.h Wed Jul 01 16:10:12 2020 +0200 +++ b/Plugin/ResourceHierarchyCache.h Mon Jul 06 16:38:30 2020 +0200 @@ -22,17 +22,18 @@ #include "Enumerations.h" #include "OrthancResource.h" +#include // For std::unique_ptr<> + #include -#include namespace OrthancPlugins { class ResourceHierarchyCache : public boost::noncopyable { private: - std::auto_ptr cache_; // Maps resources to their parents - std::auto_ptr orthancToDicom_; - std::auto_ptr dicomToOrthanc_; + std::unique_ptr cache_; // Maps resources to their parents + std::unique_ptr orthancToDicom_; + std::unique_ptr dicomToOrthanc_; std::string ComputeKey(Orthanc::ResourceType level, const std::string identifier) const; diff -r 9bdfa76c8923 -r 8ada1b669194 Resources/Orthanc/DownloadOrthancFramework.cmake --- a/Resources/Orthanc/DownloadOrthancFramework.cmake Wed Jul 01 16:10:12 2020 +0200 +++ b/Resources/Orthanc/DownloadOrthancFramework.cmake Mon Jul 06 16:38:30 2020 +0200 @@ -396,7 +396,7 @@ ## ## Case of the Orthanc framework installed as a shared library in a -## GNU/Linux distribution (typically Debian) +## GNU/Linux distribution (typically Debian). New in Orthanc 1.7.2. ## if (ORTHANC_FRAMEWORK_SOURCE STREQUAL "system") @@ -438,7 +438,7 @@ # Look for mandatory dependency Boost (cf. BoostConfiguration.cmake) include(FindBoost) - find_package(Boost COMPONENTS filesystem thread system date_time regex) + find_package(Boost COMPONENTS filesystem thread system date_time regex ${ORTHANC_BOOST_COMPONENTS}) if (NOT Boost_FOUND) message(FATAL_ERROR "Unable to locate Boost on this system") @@ -485,14 +485,6 @@ endif() endif() - # Optional component - Google Test - if (ENABLE_GOOGLE_TEST) - set(USE_SYSTEM_GOOGLE_TEST ON CACHE BOOL "Use the system version of Google Test") - set(USE_GOOGLE_TEST_DEBIAN_PACKAGE OFF CACHE BOOL "Use the sources of Google Test shipped with libgtest-dev (Debian only)") - mark_as_advanced(USE_GOOGLE_TEST_DEBIAN_PACKAGE) - include(${CMAKE_CURRENT_LIST_DIR}/GoogleTestConfiguration.cmake) - endif() - # Look for Orthanc framework shared library include(CheckCXXSymbolExists)