# HG changeset patch # User Sebastien Jodogne # Date 1545319100 -3600 # Node ID 8b331be5760655ff2748a3eca00e46c506167a6a # Parent 095193bbd7b9ff6df6fcd463f6f5fc2af4fb87ab fix build without plugins diff -r 095193bbd7b9 -r 8b331be57606 OrthancServer/OrthancRestApi/OrthancRestResources.cpp --- a/OrthancServer/OrthancRestApi/OrthancRestResources.cpp Thu Dec 20 15:24:55 2018 +0100 +++ b/OrthancServer/OrthancRestApi/OrthancRestResources.cpp Thu Dec 20 16:18:20 2018 +0100 @@ -39,6 +39,7 @@ #include "../../Core/DicomParsing/Internals/DicomImageDecoder.h" #include "../../Core/HttpServer/HttpContentNegociation.h" #include "../../Core/Logging.h" +#include "../DefaultDicomImageDecoder.h" #include "../OrthancConfiguration.h" #include "../Search/LookupResource.h" #include "../ServerContext.h" diff -r 095193bbd7b9 -r 8b331be57606 OrthancServer/main.cpp --- a/OrthancServer/main.cpp Thu Dec 20 15:24:55 2018 +0100 +++ b/OrthancServer/main.cpp Thu Dec 20 16:18:20 2018 +0100 @@ -356,11 +356,13 @@ const IHttpHandler::Arguments& httpHeaders, const IHttpHandler::GetArguments& getArguments) { +#if ORTHANC_ENABLE_PLUGINS == 1 if (plugins_ != NULL && !plugins_->IsAllowed(method, uri, ip, username, httpHeaders, getArguments)) { return false; } +#endif static const char* HTTP_FILTER = "IncomingHttpRequestFilter"; @@ -1232,8 +1234,12 @@ #elif ORTHANC_ENABLE_PLUGINS == 0 // The plugins are disabled - databasePtr.reset(lock.GetConfiguration().CreateDatabaseWrapper()); - storage.reset(lock.GetConfiguration().CreateStorageArea()); + + databasePtr.reset(CreateDatabaseWrapper()); + storage.reset(CreateStorageArea()); + + assert(databasePtr.get() != NULL); + assert(storage.get() != NULL); return ConfigureDatabase(*databasePtr, *storage, NULL, upgradeDatabase, loadJobsFromDatabase); diff -r 095193bbd7b9 -r 8b331be57606 UnitTestsSources/FromDcmtkTests.cpp --- a/UnitTestsSources/FromDcmtkTests.cpp Thu Dec 20 15:24:55 2018 +0100 +++ b/UnitTestsSources/FromDcmtkTests.cpp Thu Dec 20 16:18:20 2018 +0100 @@ -320,6 +320,7 @@ TEST(FromDcmtkBridge, ValueRepresentationConversions) { +#if ORTHANC_ENABLE_PLUGINS == 1 ASSERT_EQ(1, ValueRepresentation_ApplicationEntity); ASSERT_EQ(1, OrthancPluginValueRepresentation_AE); @@ -358,6 +359,7 @@ ValueRepresentation orthanc = Plugins::Convert(plugins); ASSERT_EQ(plugins, Plugins::Convert(orthanc)); } +#endif }