annotate OrthancServer/Plugins/Samples/AdvancedStorage/CMakeLists.txt @ 5808:63c025cf6958 attach-custom-data

cleanup
author Alain Mazy <am@orthanc.team>
date Tue, 24 Sep 2024 12:11:25 +0200
parents d7274e43ea7c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5080
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
1 # Orthanc - A Lightweight, RESTful DICOM Store
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
2 # Copyright (C) 2012-2016 Sebastien Jodogne, Medical Physics
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
3 # Department, University Hospital of Liege, Belgium
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
4 # Copyright (C) 2017-2022 Osimis S.A., Belgium
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
5 # Copyright (C) 2021-2022 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
6 #
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
7 # This program is free software: you can redistribute it and/or
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
8 # modify it under the terms of the GNU General Public License as
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
9 # published by the Free Software Foundation, either version 3 of the
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
10 # License, or (at your option) any later version.
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
11 #
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
12 # This program is distributed in the hope that it will be useful, but
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
13 # WITHOUT ANY WARRANTY; without even the implied warranty of
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
14 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
15 # General Public License for more details.
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
16 #
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
17 # You should have received a copy of the GNU General Public License
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
18 # along with this program. If not, see <http://www.gnu.org/licenses/>.
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
19
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
20
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
21 cmake_minimum_required(VERSION 2.8)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
22 cmake_policy(SET CMP0058 NEW)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
23
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
24 project(AdvancedStorage)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
25
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
26 SET(PLUGIN_VERSION "mainline" CACHE STRING "Version of the plugin")
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
27
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
28 include(${CMAKE_CURRENT_SOURCE_DIR}/../../../../OrthancFramework/Resources/CMake/OrthancFrameworkParameters.cmake)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
29 include(${CMAKE_CURRENT_SOURCE_DIR}/../../../../OrthancFramework/Resources/CMake/OrthancFrameworkConfiguration.cmake)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
30
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
31 include(${CMAKE_CURRENT_LIST_DIR}/../Common/OrthancPluginsExports.cmake)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
32
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
33 if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows")
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
34 execute_process(
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
35 COMMAND
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
36 ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Resources/WindowsResources.py
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
37 ${PLUGIN_VERSION} AdvancedStorage AdvancedStorage.dll "Orthanc plugin to extend Orthanc Storage"
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
38 ERROR_VARIABLE Failure
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
39 OUTPUT_FILE ${AUTOGENERATED_DIR}/AdvancedStorage.rc
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
40 )
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
41
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
42 if (Failure)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
43 message(FATAL_ERROR "Error while computing the version information: ${Failure}")
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
44 endif()
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
45
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
46 list(APPEND ADDITIONAL_RESOURCES ${AUTOGENERATED_DIR}/AdvancedStorage.rc)
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
47 endif()
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
48
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
49 add_definitions(
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
50 -DHAS_ORTHANC_EXCEPTION=1
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
51 -DORTHANC_PLUGIN_VERSION="${PLUGIN_VERSION}"
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
52 )
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
53
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
54 include_directories(
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
55 ${CMAKE_SOURCE_DIR}/../../Include/
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
56 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
57 )
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
58
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
59 add_library(AdvancedStorage SHARED
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
60 ${ADDITIONAL_RESOURCES}
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
61 ${AUTOGENERATED_SOURCES}
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
62 ${ORTHANC_CORE_SOURCES_DEPENDENCIES}
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
63 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/Enumerations.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
64 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/Logging.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
65 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/OrthancException.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
66 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/SystemToolbox.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
67 ${CMAKE_SOURCE_DIR}/../../../../OrthancFramework/Sources/Toolbox.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
68 ${CMAKE_SOURCE_DIR}/../../../../OrthancServer/Plugins/Samples/Common/OrthancPluginCppWrapper.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
69 Plugin.cpp
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
70 )
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
71
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
72 set_target_properties(
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
73 AdvancedStorage PROPERTIES
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
74 VERSION ${PLUGIN_VERSION}
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
75 SOVERSION ${PLUGIN_VERSION}
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
76 )
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
77
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
78 install(
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
79 TARGETS AdvancedStorage
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
80 DESTINATION .
d7274e43ea7c allow plugins to store a customData in the Attachments table to e.g. store custom paths without requiring an external DB
Alain Mazy <am@osimis.io>
parents:
diff changeset
81 )