annotate Resources/CMake/OrthancFrameworkConfiguration.cmake @ 4084:25812a487037

fix missing macros
author Sebastien Jodogne <s.jodogne@gmail.com>
date Thu, 25 Jun 2020 08:28:11 +0200
parents 052dc48c15be
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
1 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
2 ## This is a CMake configuration file that configures the core
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
3 ## libraries of Orthanc. This file can be used by external projects so
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
4 ## as to gain access to the Orthanc APIs (the most prominent examples
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
5 ## are currently "Stone of Orthanc" and "Orthanc for whole-slide
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
6 ## imaging plugin").
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
7 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
8
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
9
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
10 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
11 ## Configuration of the components
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
12 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
13
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
14 # Path to the root folder of the Orthanc distribution
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
15 set(ORTHANC_ROOT ${CMAKE_CURRENT_LIST_DIR}/../..)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
16
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
17 # Some basic inclusions
2450
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
18 include(CMakePushCheckState)
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
19 include(CheckFunctionExists)
2450
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
20 include(CheckIncludeFile)
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
21 include(CheckIncludeFileCXX)
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
22 include(CheckIncludeFiles)
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
23 include(CheckLibraryExists)
2450
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
24 include(CheckStructHasMember)
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
25 include(CheckSymbolExists)
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
26 include(CheckTypeSize)
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
27 include(FindPythonInterp)
2450
ade8b4ddd8a6 Static linking against libuuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2444
diff changeset
28
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
29 include(${CMAKE_CURRENT_LIST_DIR}/AutoGeneratedCode.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30 include(${CMAKE_CURRENT_LIST_DIR}/DownloadPackage.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 include(${CMAKE_CURRENT_LIST_DIR}/Compiler.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 #####################################################################
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
35 ## Disable unneeded macros
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
36 #####################################################################
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
37
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
38 if (NOT ENABLE_SQLITE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
39 unset(USE_SYSTEM_SQLITE CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
40 add_definitions(-DORTHANC_ENABLE_SQLITE=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
41 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
42
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
43 if (NOT ENABLE_CRYPTO_OPTIONS)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
44 unset(ENABLE_SSL CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
45 unset(ENABLE_PKCS11 CACHE)
2676
d2f70c8f8bfd primitives to compile OpenSSL within MariaDB
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2657
diff changeset
46 unset(ENABLE_OPENSSL_ENGINES CACHE)
3979
464d40d572bd removed unused CMake settings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3973
diff changeset
47 unset(OPENSSL_STATIC_VERSION CACHE)
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
48 unset(USE_SYSTEM_OPENSSL CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
49 unset(USE_SYSTEM_LIBP11 CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
50 add_definitions(
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
51 -DORTHANC_ENABLE_SSL=0
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
52 -DORTHANC_ENABLE_PKCS11=0
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
53 )
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
54 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
55
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
56 if (NOT ENABLE_WEB_CLIENT)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
57 unset(USE_SYSTEM_CURL CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
58 add_definitions(-DORTHANC_ENABLE_CURL=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
59 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
60
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
61 if (NOT ENABLE_WEB_SERVER)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
62 unset(ENABLE_CIVETWEB CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
63 unset(USE_SYSTEM_CIVETWEB CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
64 unset(USE_SYSTEM_MONGOOSE CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
65 add_definitions(
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
66 -DORTHANC_ENABLE_CIVETWEB=0
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
67 -DORTHANC_ENABLE_MONGOOSE=0
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
68 )
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
69 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
70
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
71 if (NOT ENABLE_JPEG)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
72 unset(USE_SYSTEM_LIBJPEG CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
73 add_definitions(-DORTHANC_ENABLE_JPEG=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
74 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
75
2508
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
76 if (NOT ENABLE_ZLIB)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
77 unset(USE_SYSTEM_ZLIB CACHE)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
78 add_definitions(-DORTHANC_ENABLE_ZLIB=0)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
79 endif()
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
80
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
81 if (NOT ENABLE_PNG)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
82 unset(USE_SYSTEM_LIBPNG CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
83 add_definitions(-DORTHANC_ENABLE_PNG=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
84 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
85
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
86 if (NOT ENABLE_LUA)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
87 unset(USE_SYSTEM_LUA CACHE)
2685
6801f99bbc2f Configuration option "LogExportedResources" is now "false" by default
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2676
diff changeset
88 unset(ENABLE_LUA_MODULES CACHE)
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
89 add_definitions(-DORTHANC_ENABLE_LUA=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
90 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
91
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
92 if (NOT ENABLE_PUGIXML)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
93 unset(USE_SYSTEM_PUGIXML CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
94 add_definitions(-DORTHANC_ENABLE_PUGIXML=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
95 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
96
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
97 if (NOT ENABLE_LOCALE)
3228
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
98 unset(BOOST_LOCALE_BACKEND CACHE)
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
99 add_definitions(-DORTHANC_ENABLE_LOCALE=0)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
100 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
101
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
102 if (NOT ENABLE_GOOGLE_TEST)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
103 unset(USE_SYSTEM_GOOGLE_TEST CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
104 unset(USE_GOOGLE_TEST_DEBIAN_PACKAGE CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
105 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
106
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
107 if (NOT ENABLE_DCMTK)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
108 add_definitions(
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
109 -DORTHANC_ENABLE_DCMTK=0
4084
25812a487037 fix missing macros
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4040
diff changeset
110 -DORTHANC_ENABLE_DCMTK_JPEG=0
25812a487037 fix missing macros
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4040
diff changeset
111 -DORTHANC_ENABLE_DCMTK_JPEG_LOSSLESS=0
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
112 -DORTHANC_ENABLE_DCMTK_NETWORKING=0
3727
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
113 -DORTHANC_ENABLE_DCMTK_TRANSCODING=0
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
114 )
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
115 unset(DCMTK_DICTIONARY_DIR CACHE)
3274
95b0536be2c3 preparing for dcmtk 3.6.4
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3241
diff changeset
116 unset(DCMTK_VERSION CACHE)
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
117 unset(USE_DCMTK_362_PRIVATE_DIC CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
118 unset(USE_SYSTEM_DCMTK CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
119 unset(ENABLE_DCMTK_JPEG CACHE)
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
120 unset(ENABLE_DCMTK_JPEG_LOSSLESS CACHE)
3979
464d40d572bd removed unused CMake settings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3973
diff changeset
121 unset(DCMTK_STATIC_VERSION CACHE)
464d40d572bd removed unused CMake settings
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3973
diff changeset
122 unset(ENABLE_DCMTK_LOG CACHE)
2429
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
123 endif()
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
124
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
125
fe90b3ec9d4a improvement in Orthanc framework config
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2407
diff changeset
126 #####################################################################
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
127 ## List of source files
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
128 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
129
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
130 set(ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
131 ${ORTHANC_ROOT}/Core/Cache/MemoryCache.cpp
3557
4d809b2e1141 better cache toolbox: MemoryObjectCache
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3554
diff changeset
132 ${ORTHANC_ROOT}/Core/Cache/MemoryObjectCache.cpp
4d809b2e1141 better cache toolbox: MemoryObjectCache
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3554
diff changeset
133 ${ORTHANC_ROOT}/Core/Cache/MemoryStringCache.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
134 ${ORTHANC_ROOT}/Core/ChunkedBuffer.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
135 ${ORTHANC_ROOT}/Core/DicomFormat/DicomTag.cpp
2975
e62e296a5714 use Toolbox::IsIntegeer instead of try_lexical_convert that is not available on some platform
am@osimis.io
parents: 2860
diff changeset
136 ${ORTHANC_ROOT}/Core/EnumerationDictionary.h
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
137 ${ORTHANC_ROOT}/Core/Enumerations.cpp
2651
1da5a052c777 testing value serialization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2621
diff changeset
138 ${ORTHANC_ROOT}/Core/FileStorage/MemoryStorageArea.cpp
3398
4acd1431e603 new classes: StringMatcher and MultipartStreamReader
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3357
diff changeset
139 ${ORTHANC_ROOT}/Core/HttpServer/MultipartStreamReader.cpp
4acd1431e603 new classes: StringMatcher and MultipartStreamReader
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3357
diff changeset
140 ${ORTHANC_ROOT}/Core/HttpServer/StringMatcher.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
141 ${ORTHANC_ROOT}/Core/Logging.cpp
4026
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
142 ${ORTHANC_ROOT}/Core/OrthancFramework.cpp
2656
a6d3e45eeff5 SerializationToolbox
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2651
diff changeset
143 ${ORTHANC_ROOT}/Core/SerializationToolbox.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
144 ${ORTHANC_ROOT}/Core/Toolbox.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
145 ${ORTHANC_ROOT}/Core/WebServiceParameters.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
146 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
147
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
148 if (ENABLE_MODULE_IMAGES)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
149 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
150 ${ORTHANC_ROOT}/Core/Images/Font.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
151 ${ORTHANC_ROOT}/Core/Images/FontRegistry.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
152 ${ORTHANC_ROOT}/Core/Images/IImageWriter.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
153 ${ORTHANC_ROOT}/Core/Images/Image.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
154 ${ORTHANC_ROOT}/Core/Images/ImageAccessor.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
155 ${ORTHANC_ROOT}/Core/Images/ImageBuffer.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
156 ${ORTHANC_ROOT}/Core/Images/ImageProcessing.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
157 ${ORTHANC_ROOT}/Core/Images/PamReader.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
158 ${ORTHANC_ROOT}/Core/Images/PamWriter.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
159 )
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
160 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
161
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
162 if (ENABLE_MODULE_DICOM)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
163 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
164 ${ORTHANC_ROOT}/Core/DicomFormat/DicomArray.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
165 ${ORTHANC_ROOT}/Core/DicomFormat/DicomImageInformation.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
166 ${ORTHANC_ROOT}/Core/DicomFormat/DicomInstanceHasher.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
167 ${ORTHANC_ROOT}/Core/DicomFormat/DicomIntegerPixelAccessor.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
168 ${ORTHANC_ROOT}/Core/DicomFormat/DicomMap.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
169 ${ORTHANC_ROOT}/Core/DicomFormat/DicomValue.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
170 )
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
171 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
172
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
173 if (ENABLE_MODULE_JOBS)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
174 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
175 ${ORTHANC_ROOT}/Core/JobsEngine/GenericJobUnserializer.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
176 ${ORTHANC_ROOT}/Core/JobsEngine/JobInfo.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
177 ${ORTHANC_ROOT}/Core/JobsEngine/JobStatus.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
178 ${ORTHANC_ROOT}/Core/JobsEngine/JobStepResult.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
179 ${ORTHANC_ROOT}/Core/JobsEngine/Operations/JobOperationValues.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
180 ${ORTHANC_ROOT}/Core/JobsEngine/Operations/LogJobOperation.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
181 ${ORTHANC_ROOT}/Core/JobsEngine/Operations/SequenceOfOperationsJob.cpp
2860
8b00e4cb4a6b SetOfCommandsJob
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2794
diff changeset
182 ${ORTHANC_ROOT}/Core/JobsEngine/SetOfCommandsJob.cpp
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
183 ${ORTHANC_ROOT}/Core/JobsEngine/SetOfInstancesJob.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
184 )
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
185 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
186
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
187
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
188
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
189 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
190 ## Configuration of optional third-party dependencies
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
191 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
192
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
193
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
194 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
195 ## Embedded database: SQLite
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
196 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
197
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
198 if (ENABLE_SQLITE)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
199 include(${CMAKE_CURRENT_LIST_DIR}/SQLiteConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
200 add_definitions(-DORTHANC_ENABLE_SQLITE=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
201
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
202 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
203 ${ORTHANC_ROOT}/Core/SQLite/Connection.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
204 ${ORTHANC_ROOT}/Core/SQLite/FunctionContext.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
205 ${ORTHANC_ROOT}/Core/SQLite/Statement.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
206 ${ORTHANC_ROOT}/Core/SQLite/StatementId.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
207 ${ORTHANC_ROOT}/Core/SQLite/StatementReference.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
208 ${ORTHANC_ROOT}/Core/SQLite/Transaction.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
209 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
210 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
211
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
212
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
213 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
214 ## Cryptography: OpenSSL and libp11
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
215 ## Must be above "ENABLE_WEB_CLIENT" and "ENABLE_WEB_SERVER"
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
216 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
217
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
218 if (ENABLE_CRYPTO_OPTIONS)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
219 if (ENABLE_SSL)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
220 include(${CMAKE_CURRENT_LIST_DIR}/OpenSslConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
221 add_definitions(-DORTHANC_ENABLE_SSL=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
222 else()
2676
d2f70c8f8bfd primitives to compile OpenSSL within MariaDB
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2657
diff changeset
223 unset(ENABLE_OPENSSL_ENGINES CACHE)
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
224 unset(USE_SYSTEM_OPENSSL CACHE)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
225 add_definitions(-DORTHANC_ENABLE_SSL=0)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
226 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
227
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
228 if (ENABLE_PKCS11)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
229 if (ENABLE_SSL)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
230 include(${CMAKE_CURRENT_LIST_DIR}/LibP11Configuration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
231
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
232 add_definitions(-DORTHANC_ENABLE_PKCS11=1)
2392
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
233 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
234 ${ORTHANC_ROOT}/Core/Pkcs11.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
235 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
236 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
237 message(FATAL_ERROR "OpenSSL is required to enable PKCS#11 support")
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
238 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
239 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
240 add_definitions(-DORTHANC_ENABLE_PKCS11=0)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
241 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
242 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
243
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
244
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
245 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
246 ## HTTP client: libcurl
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
247 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
248
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
249 if (ENABLE_WEB_CLIENT)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
250 include(${CMAKE_CURRENT_LIST_DIR}/LibCurlConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
251 add_definitions(-DORTHANC_ENABLE_CURL=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
252
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
253 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
254 ${ORTHANC_ROOT}/Core/HttpClient.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
255 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
256 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
257
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
258
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
259 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
260 ## HTTP server: Mongoose 3.8 or Civetweb
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
261 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
262
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
263 if (ENABLE_WEB_SERVER)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
264 if (ENABLE_CIVETWEB)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
265 include(${CMAKE_CURRENT_LIST_DIR}/CivetwebConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
266 add_definitions(
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
267 -DORTHANC_ENABLE_CIVETWEB=1
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
268 -DORTHANC_ENABLE_MONGOOSE=0
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
269 )
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
270 set(ORTHANC_ENABLE_CIVETWEB 1)
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
271 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
272 include(${CMAKE_CURRENT_LIST_DIR}/MongooseConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
273 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
274
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
275 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
276 ${ORTHANC_ROOT}/Core/HttpServer/BufferHttpSender.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
277 ${ORTHANC_ROOT}/Core/HttpServer/FilesystemHttpHandler.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
278 ${ORTHANC_ROOT}/Core/HttpServer/FilesystemHttpSender.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
279 ${ORTHANC_ROOT}/Core/HttpServer/HttpContentNegociation.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
280 ${ORTHANC_ROOT}/Core/HttpServer/HttpFileSender.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
281 ${ORTHANC_ROOT}/Core/HttpServer/HttpOutput.cpp
3138
ab46e537f92e renamed class MongooseServer as HttpServer, CivetWeb made default HTTP server
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2988
diff changeset
282 ${ORTHANC_ROOT}/Core/HttpServer/HttpServer.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
283 ${ORTHANC_ROOT}/Core/HttpServer/HttpStreamTranscoder.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
284 ${ORTHANC_ROOT}/Core/HttpServer/HttpToolbox.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
285 ${ORTHANC_ROOT}/Core/HttpServer/StringHttpOutput.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
286 ${ORTHANC_ROOT}/Core/RestApi/RestApi.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
287 ${ORTHANC_ROOT}/Core/RestApi/RestApiCall.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
288 ${ORTHANC_ROOT}/Core/RestApi/RestApiGetCall.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
289 ${ORTHANC_ROOT}/Core/RestApi/RestApiHierarchy.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
290 ${ORTHANC_ROOT}/Core/RestApi/RestApiOutput.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
291 ${ORTHANC_ROOT}/Core/RestApi/RestApiPath.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
292 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
293 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
294
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
295 if (ORTHANC_ENABLE_CIVETWEB)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
296 add_definitions(-DORTHANC_ENABLE_CIVETWEB=1)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
297 else()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
298 add_definitions(-DORTHANC_ENABLE_CIVETWEB=0)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
299 endif()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
300
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
301 if (ORTHANC_ENABLE_MONGOOSE)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
302 add_definitions(-DORTHANC_ENABLE_MONGOOSE=1)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
303 else()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
304 add_definitions(-DORTHANC_ENABLE_MONGOOSE=0)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
305 endif()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
306
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
307
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
308
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
309 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
310 ## JPEG support: libjpeg
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
311 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
312
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
313 if (ENABLE_JPEG)
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
314 if (NOT ENABLE_MODULE_IMAGES)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
315 message(FATAL_ERROR "Image processing primitives must be enabled if enabling libjpeg support")
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
316 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
317
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
318 include(${CMAKE_CURRENT_LIST_DIR}/LibJpegConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
319 add_definitions(-DORTHANC_ENABLE_JPEG=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
320
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
321 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
322 ${ORTHANC_ROOT}/Core/Images/JpegErrorManager.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
323 ${ORTHANC_ROOT}/Core/Images/JpegReader.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
324 ${ORTHANC_ROOT}/Core/Images/JpegWriter.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
325 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
326 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
327
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
328
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
329 ##
2508
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
330 ## zlib support
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
331 ##
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
332
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
333 if (ENABLE_ZLIB)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
334 include(${CMAKE_CURRENT_LIST_DIR}/ZlibConfiguration.cmake)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
335 add_definitions(-DORTHANC_ENABLE_ZLIB=1)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
336
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
337 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
338 ${ORTHANC_ROOT}/Core/Compression/DeflateBaseCompressor.cpp
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
339 ${ORTHANC_ROOT}/Core/Compression/GzipCompressor.cpp
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
340 ${ORTHANC_ROOT}/Core/Compression/ZlibCompressor.cpp
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
341 )
2529
ae5f98eadb75 fix in Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2516
diff changeset
342
ae5f98eadb75 fix in Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2516
diff changeset
343 if (NOT ORTHANC_SANDBOXED)
ae5f98eadb75 fix in Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2516
diff changeset
344 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
2782
64e3d4ab158d find sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2708
diff changeset
345 ${ORTHANC_ROOT}/Core/Compression/HierarchicalZipWriter.cpp
64e3d4ab158d find sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2708
diff changeset
346 ${ORTHANC_ROOT}/Core/Compression/ZipWriter.cpp
2529
ae5f98eadb75 fix in Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2516
diff changeset
347 ${ORTHANC_ROOT}/Core/FileStorage/StorageAccessor.cpp
2782
64e3d4ab158d find sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2708
diff changeset
348 )
2529
ae5f98eadb75 fix in Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2516
diff changeset
349 endif()
2508
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
350 endif()
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
351
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
352
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
353 ##
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
354 ## PNG support: libpng (in conjunction with zlib)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
355 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
356
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
357 if (ENABLE_PNG)
2508
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
358 if (NOT ENABLE_ZLIB)
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
359 message(FATAL_ERROR "Support for zlib must be enabled if enabling libpng support")
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
360 endif()
91ee08d986f9 possibility to disable zlib support in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2483
diff changeset
361
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
362 if (NOT ENABLE_MODULE_IMAGES)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
363 message(FATAL_ERROR "Image processing primitives must be enabled if enabling libpng support")
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
364 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
365
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
366 include(${CMAKE_CURRENT_LIST_DIR}/LibPngConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
367 add_definitions(-DORTHANC_ENABLE_PNG=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
368
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
369 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
370 ${ORTHANC_ROOT}/Core/Images/PngReader.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
371 ${ORTHANC_ROOT}/Core/Images/PngWriter.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
372 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
373 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
374
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
375
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
376 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
377 ## Lua support
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
378 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
379
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
380 if (ENABLE_LUA)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
381 include(${CMAKE_CURRENT_LIST_DIR}/LuaConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
382 add_definitions(-DORTHANC_ENABLE_LUA=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
383
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
384 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
385 ${ORTHANC_ROOT}/Core/Lua/LuaContext.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
386 ${ORTHANC_ROOT}/Core/Lua/LuaFunctionCall.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
387 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
388 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
389
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
390
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
391 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
392 ## XML support: pugixml
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
393 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
394
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
395 if (ENABLE_PUGIXML)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
396 include(${CMAKE_CURRENT_LIST_DIR}/PugixmlConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
397 add_definitions(-DORTHANC_ENABLE_PUGIXML=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
398 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
399
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
400
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
401 ##
3228
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
402 ## Locale support
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
403 ##
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
404
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
405 if (ENABLE_LOCALE)
2513
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
406 if (CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
407 # In WebAssembly or asm.js, we rely on the version of iconv that
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
408 # is shipped with the stdlib
3228
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
409 unset(BOOST_LOCALE_BACKEND CACHE)
2513
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
410 else()
3241
32596919d729 first compilation combining ICU and LSB
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3228
diff changeset
411 if (BOOST_LOCALE_BACKEND STREQUAL "gcc")
32596919d729 first compilation combining ICU and LSB
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3228
diff changeset
412 elseif (BOOST_LOCALE_BACKEND STREQUAL "libiconv")
3228
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
413 include(${CMAKE_CURRENT_LIST_DIR}/LibIconvConfiguration.cmake)
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
414 elseif (BOOST_LOCALE_BACKEND STREQUAL "icu")
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
415 include(${CMAKE_CURRENT_LIST_DIR}/LibIcuConfiguration.cmake)
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
416 elseif (BOOST_LOCALE_BACKEND STREQUAL "wconv")
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
417 message("Using Microsoft Window's wconv")
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
418 else()
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
419 message(FATAL_ERROR "Invalid value for BOOST_LOCALE_BACKEND: ${BOOST_LOCALE_BACKEND}")
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
420 endif()
2513
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
421 endif()
97a74f0eac7a loading DICOM dictionaries in sandboxed environments
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2512
diff changeset
422
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
423 add_definitions(-DORTHANC_ENABLE_LOCALE=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
424 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
425
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
426
2404
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
427 ##
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
428 ## Google Test for unit testing
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
429 ##
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
430
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
431 if (ENABLE_GOOGLE_TEST)
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
432 include(${CMAKE_CURRENT_LIST_DIR}/GoogleTestConfiguration.cmake)
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
433 endif()
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
434
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
435
e6af2c5cd0f1 migration of Google Test into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2397
diff changeset
436
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
437 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
438 ## Inclusion of mandatory third-party dependencies
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
439 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
440
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
441 include(${CMAKE_CURRENT_LIST_DIR}/JsonCppConfiguration.cmake)
2512
4dcafa8d6633 SystemToolbox::GenerateUuid moved to Toolbox::GenerateUuid
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2511
diff changeset
442 include(${CMAKE_CURRENT_LIST_DIR}/UuidConfiguration.cmake)
2465
80c1ed8e7283 uuid not available if sandboxed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2463
diff changeset
443
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
444 # We put Boost as the last dependency, as it is the heaviest to
3973
d86bddb50972 fix spelling errors according to debian
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3920
diff changeset
445 # configure, which allows one to quickly spot problems when configuring
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
446 # static builds in other dependencies
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
447 include(${CMAKE_CURRENT_LIST_DIR}/BoostConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
448
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
449
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
450 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
451 ## Optional configuration of DCMTK
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
452 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
453
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
454 if (ENABLE_DCMTK)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
455 if (NOT ENABLE_LOCALE)
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
456 message(FATAL_ERROR "Support for locales must be enabled if enabling DCMTK support")
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
457 endif()
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
458
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
459 if (NOT ENABLE_MODULE_DICOM)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
460 message(FATAL_ERROR "DICOM module must be enabled if enabling DCMTK support")
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
461 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
462
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
463 include(${CMAKE_CURRENT_LIST_DIR}/DcmtkConfiguration.cmake)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
464
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
465 add_definitions(-DORTHANC_ENABLE_DCMTK=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
466
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
467 if (ENABLE_DCMTK_JPEG)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
468 add_definitions(-DORTHANC_ENABLE_DCMTK_JPEG=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
469 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
470 add_definitions(-DORTHANC_ENABLE_DCMTK_JPEG=0)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
471 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
472
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
473 if (ENABLE_DCMTK_JPEG_LOSSLESS)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
474 add_definitions(-DORTHANC_ENABLE_DCMTK_JPEG_LOSSLESS=1)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
475 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
476 add_definitions(-DORTHANC_ENABLE_DCMTK_JPEG_LOSSLESS=0)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
477 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
478
2391
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
479 set(ORTHANC_DICOM_SOURCES_INTERNAL
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
480 ${ORTHANC_ROOT}/Core/DicomParsing/DicomModification.cpp
3202
ef4d86d05503 reorganization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3174
diff changeset
481 ${ORTHANC_ROOT}/Core/DicomParsing/DicomWebJsonVisitor.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
482 ${ORTHANC_ROOT}/Core/DicomParsing/FromDcmtkBridge.cpp
3554
8fe89c2ea593 new class: ParsedDicomDir
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3398
diff changeset
483 ${ORTHANC_ROOT}/Core/DicomParsing/ParsedDicomDir.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
484 ${ORTHANC_ROOT}/Core/DicomParsing/ParsedDicomFile.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
485 ${ORTHANC_ROOT}/Core/DicomParsing/ToDcmtkBridge.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
486
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
487 ${ORTHANC_ROOT}/Core/DicomParsing/Internals/DicomFrameIndex.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
488 ${ORTHANC_ROOT}/Core/DicomParsing/Internals/DicomImageDecoder.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
489 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
490
2516
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
491 if (NOT ORTHANC_SANDBOXED)
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
492 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
493 ${ORTHANC_ROOT}/Core/DicomParsing/DicomDirWriter.cpp
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
494 )
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
495 endif()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2514
diff changeset
496
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
497 if (ENABLE_DCMTK_NETWORKING)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
498 add_definitions(-DORTHANC_ENABLE_DCMTK_NETWORKING=1)
2391
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
499 list(APPEND ORTHANC_DICOM_SOURCES_INTERNAL
3825
4570c57668a8 refactoring DicomUserConnection as Dicom[Control|Store]UserConnection
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3727
diff changeset
500 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomAssociation.cpp
4570c57668a8 refactoring DicomUserConnection as Dicom[Control|Store]UserConnection
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3727
diff changeset
501 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomAssociationParameters.cpp
4570c57668a8 refactoring DicomUserConnection as Dicom[Control|Store]UserConnection
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3727
diff changeset
502 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomControlUserConnection.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
503 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomFindAnswers.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
504 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomServer.cpp
3864
ce5c4b9fa09a removing DicomUserConnection
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3825
diff changeset
505 ${ORTHANC_ROOT}/Core/DicomNetworking/DicomStoreUserConnection.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
506 ${ORTHANC_ROOT}/Core/DicomNetworking/Internals/CommandDispatcher.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
507 ${ORTHANC_ROOT}/Core/DicomNetworking/Internals/FindScp.cpp
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
508 ${ORTHANC_ROOT}/Core/DicomNetworking/Internals/MoveScp.cpp
3818
4f78da5613a1 Add C-GET SCP support
Stacy Loesch <stacy.loesch@varian.com>
parents: 3727
diff changeset
509 ${ORTHANC_ROOT}/Core/DicomNetworking/Internals/GetScp.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
510 ${ORTHANC_ROOT}/Core/DicomNetworking/Internals/StoreScp.cpp
2610
3ff4c50647ea moving the old scheduler to the graveyard
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2603
diff changeset
511 ${ORTHANC_ROOT}/Core/DicomNetworking/RemoteModalityParameters.cpp
3ff4c50647ea moving the old scheduler to the graveyard
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2603
diff changeset
512 ${ORTHANC_ROOT}/Core/DicomNetworking/TimeoutDicomConnectionManager.cpp
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
513 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
514 else()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
515 add_definitions(-DORTHANC_ENABLE_DCMTK_NETWORKING=0)
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
516 endif()
2397
98c2a9c2c0fc automated inclusion of DICOM dictionaries
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2396
diff changeset
517
3727
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
518 # New in Orthanc 1.6.0
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
519 if (ENABLE_DCMTK_TRANSCODING)
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
520 add_definitions(-DORTHANC_ENABLE_DCMTK_TRANSCODING=1)
3893
7a5fa8f307e9 reorganization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3864
diff changeset
521 list(APPEND ORTHANC_DICOM_SOURCES_INTERNAL
7a5fa8f307e9 reorganization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3864
diff changeset
522 ${ORTHANC_ROOT}/Core/DicomParsing/DcmtkTranscoder.cpp
3906
f0dd5ded8927 refactoring using IDicomTranscoder::TranscodedDicom
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3893
diff changeset
523 ${ORTHANC_ROOT}/Core/DicomParsing/IDicomTranscoder.cpp
3893
7a5fa8f307e9 reorganization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3864
diff changeset
524 ${ORTHANC_ROOT}/Core/DicomParsing/MemoryBufferTranscoder.cpp
7a5fa8f307e9 reorganization
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3864
diff changeset
525 )
3727
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
526 else()
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
527 add_definitions(-DORTHANC_ENABLE_DCMTK_TRANSCODING=0)
090022f1b5e1 auto-generation of primitives to handle transfer syntaxes
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3557
diff changeset
528 endif()
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
529 endif()
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
530
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
531
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
532 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
533 ## Configuration of the C/C++ macros
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
534 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
535
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
536 add_definitions(
3305
aee8d160df43 changed API version to number 2
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3274
diff changeset
537 -DORTHANC_API_VERSION=${ORTHANC_API_VERSION}
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
538 -DORTHANC_DATABASE_VERSION=${ORTHANC_DATABASE_VERSION}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
539 -DORTHANC_DEFAULT_DICOM_ENCODING=Encoding_Latin1
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
540 -DORTHANC_ENABLE_BASE64=1
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
541 -DORTHANC_ENABLE_MD5=1
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
542 -DORTHANC_MAXIMUM_TAG_LENGTH=256
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
543 -DORTHANC_VERSION="${ORTHANC_VERSION}"
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
544 )
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
545
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
546
4026
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
547 if (ORTHANC_BUILDING_FRAMEWORK_LIBRARY)
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
548 add_definitions(-DORTHANC_BUILDING_FRAMEWORK_LIBRARY=1)
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
549 else()
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
550 add_definitions(-DORTHANC_BUILDING_FRAMEWORK_LIBRARY=0)
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
551 endif()
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
552
05a363186da6 ORTHANC_BUILDING_FRAMEWORK_LIBRARY, Orthanc::InitializeFramework()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4015
diff changeset
553
2406
f0cfacd0c9b8 Orthanc framework: ORTHANC_SANDBOXED parameter
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2404
diff changeset
554 if (ORTHANC_SANDBOXED)
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
555 add_definitions(
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
556 -DORTHANC_SANDBOXED=1
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
557 )
2483
9c54c40eaf25 logging primitives for WebAssembly
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2465
diff changeset
558
9c54c40eaf25 logging primitives for WebAssembly
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2465
diff changeset
559 if (CMAKE_SYSTEM_NAME STREQUAL "Emscripten")
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
560 set(ORTHANC_ENABLE_LOGGING ON)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
561 set(ORTHANC_ENABLE_LOGGING_STDIO ON)
2483
9c54c40eaf25 logging primitives for WebAssembly
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2465
diff changeset
562 else()
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
563 set(ORTHANC_ENABLE_LOGGING OFF)
2483
9c54c40eaf25 logging primitives for WebAssembly
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2465
diff changeset
564 endif()
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
565
2406
f0cfacd0c9b8 Orthanc framework: ORTHANC_SANDBOXED parameter
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2404
diff changeset
566 else()
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
567 set(ORTHANC_ENABLE_LOGGING ON)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
568 set(ORTHANC_ENABLE_LOGGING_STDIO OFF)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
569
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
570 add_definitions(
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
571 -DORTHANC_SANDBOXED=0
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
572 )
2536
e0e377a48626 ORTHANC_FRAMEWORK_PLUGIN
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2529
diff changeset
573
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
574 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
575 ${ORTHANC_ROOT}/Core/Cache/SharedArchive.cpp
3357
c0aa5f1cf2f5 new class: FileBuffer
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3305
diff changeset
576 ${ORTHANC_ROOT}/Core/FileBuffer.cpp
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
577 ${ORTHANC_ROOT}/Core/FileStorage/FilesystemStorage.cpp
3174
8ea7c4546c3a primitives to collect metrics in Orthanc
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3138
diff changeset
578 ${ORTHANC_ROOT}/Core/MetricsRegistry.cpp
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
579 ${ORTHANC_ROOT}/Core/MultiThreading/RunnableWorkersPool.cpp
2794
f790999a250a Semaphore removed from graveyard, SystemToolbox::GetHardwareConcurrency()
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2791
diff changeset
580 ${ORTHANC_ROOT}/Core/MultiThreading/Semaphore.cpp
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
581 ${ORTHANC_ROOT}/Core/MultiThreading/SharedMessageQueue.cpp
2463
be5c0f4155f6 move SharedLibrary into OrthancFramework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2453
diff changeset
582 ${ORTHANC_ROOT}/Core/SharedLibrary.cpp
2407
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
583 ${ORTHANC_ROOT}/Core/SystemToolbox.cpp
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
584 ${ORTHANC_ROOT}/Core/TemporaryFile.cpp
5edec967055e fix sandboxed builds
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2406
diff changeset
585 )
2791
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
586
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
587 if (ENABLE_MODULE_JOBS)
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
588 list(APPEND ORTHANC_CORE_SOURCES_INTERNAL
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
589 ${ORTHANC_ROOT}/Core/JobsEngine/JobsEngine.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
590 ${ORTHANC_ROOT}/Core/JobsEngine/JobsRegistry.cpp
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
591 )
d015fa861e3c selective disabling of modules in the Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2785
diff changeset
592 endif()
2406
f0cfacd0c9b8 Orthanc framework: ORTHANC_SANDBOXED parameter
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2404
diff changeset
593 endif()
f0cfacd0c9b8 Orthanc framework: ORTHANC_SANDBOXED parameter
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2404
diff changeset
594
f0cfacd0c9b8 Orthanc framework: ORTHANC_SANDBOXED parameter
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2404
diff changeset
595
3992
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
596
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
597 if (ORTHANC_ENABLE_LOGGING)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
598 add_definitions(-DORTHANC_ENABLE_LOGGING=1)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
599 else()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
600 add_definitions(-DORTHANC_ENABLE_LOGGING=0)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
601 endif()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
602
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
603 if (ORTHANC_ENABLE_LOGGING_STDIO)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
604 add_definitions(-DORTHANC_ENABLE_LOGGING_STDIO=1)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
605 else()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
606 add_definitions(-DORTHANC_ENABLE_LOGGING_STDIO=0)
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
607 endif()
f9863630ec7f working on the shared library for Orthanc framework
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3985
diff changeset
608
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
609
2988
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
610
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
611 #####################################################################
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
612 ## Configuration of Orthanc versioning macros (new in Orthanc 1.5.0)
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
613 #####################################################################
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
614
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
615 if (ORTHANC_VERSION STREQUAL "mainline")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
616 set(ORTHANC_VERSION_MAJOR "999")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
617 set(ORTHANC_VERSION_MINOR "999")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
618 set(ORTHANC_VERSION_REVISION "999")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
619 else()
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
620 string(REGEX REPLACE "^([0-9]*)\\.([0-9]*)\\.([0-9]*)$" "\\1" ORTHANC_VERSION_MAJOR ${ORTHANC_VERSION})
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
621 string(REGEX REPLACE "^([0-9]*)\\.([0-9]*)\\.([0-9]*)$" "\\2" ORTHANC_VERSION_MINOR ${ORTHANC_VERSION})
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
622 string(REGEX REPLACE "^([0-9]*)\\.([0-9]*)\\.([0-9]*)$" "\\3" ORTHANC_VERSION_REVISION ${ORTHANC_VERSION})
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
623
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
624 if (NOT ORTHANC_VERSION STREQUAL
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
625 "${ORTHANC_VERSION_MAJOR}.${ORTHANC_VERSION_MINOR}.${ORTHANC_VERSION_REVISION}")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
626 message(FATAL_ERROR "Error in the (x.y.z) format of the Orthanc version: ${ORTHANC_VERSION}")
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
627 endif()
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
628 endif()
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
629
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
630 add_definitions(
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
631 -DORTHANC_VERSION_MAJOR=${ORTHANC_VERSION_MAJOR}
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
632 -DORTHANC_VERSION_MINOR=${ORTHANC_VERSION_MINOR}
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
633 -DORTHANC_VERSION_REVISION=${ORTHANC_VERSION_REVISION}
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
634 )
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
635
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
636
9cc3d40e389b Orthanc 1.4.3 is now known as 1.5.0
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2975
diff changeset
637
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
638 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
639 ## Gathering of all the source code
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
640 #####################################################################
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
641
2392
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
642 # The "xxx_INTERNAL" variables list the source code that belongs to
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
643 # the Orthanc project. It can be used to configure precompiled headers
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
644 # if using Microsoft Visual Studio.
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
645
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
646 # The "xxx_DEPENDENCIES" variables list the source code coming from
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
647 # third-party dependencies.
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
648
a88c3ea0c96d getting rid of the OpenSSL static library
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2391
diff changeset
649
2390
cf0eb76c5e81 fix precompiled headers
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2388
diff changeset
650 set(ORTHANC_CORE_SOURCES_DEPENDENCIES
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
651 ${BOOST_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
652 ${CIVETWEB_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
653 ${CURL_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
654 ${JSONCPP_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
655 ${LIBICONV_SOURCES}
3228
4b9cfd92d1ae preparing for libicu
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 3202
diff changeset
656 ${LIBICU_SOURCES}
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
657 ${LIBJPEG_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
658 ${LIBP11_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
659 ${LIBPNG_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
660 ${LUA_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
661 ${MONGOOSE_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
662 ${OPENSSL_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
663 ${PUGIXML_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
664 ${SQLITE_SOURCES}
2453
c50413a4092c missing generated file in e2fsprogs
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2450
diff changeset
665 ${UUID_SOURCES}
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
666 ${ZLIB_SOURCES}
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
667
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
668 ${ORTHANC_ROOT}/Resources/ThirdParty/md5/md5.c
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
669 ${ORTHANC_ROOT}/Resources/ThirdParty/base64/base64.cpp
2785
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
670 )
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
671
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
672 if (ENABLE_ZLIB AND NOT ORTHANC_SANDBOXED)
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
673 list(APPEND ORTHANC_CORE_SOURCES_DEPENDENCIES
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
674 # This is the minizip distribution to create ZIP files using zlib
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
675 ${ORTHANC_ROOT}/Resources/ThirdParty/minizip/ioapi.c
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
676 ${ORTHANC_ROOT}/Resources/ThirdParty/minizip/zip.c
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
677 )
a16ad34d46f1 fix msvc build
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2784
diff changeset
678 endif()
2390
cf0eb76c5e81 fix precompiled headers
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2388
diff changeset
679
2514
38d666a40860 fix msvc
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2513
diff changeset
680
4040
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
681 if (NOT "${LIBICU_RESOURCES}" STREQUAL "" OR
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
682 NOT "${DCMTK_DICTIONARIES}" STREQUAL "")
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
683 EmbedResources(
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
684 --namespace=Orthanc.FrameworkResources
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
685 --target=OrthancFrameworkResources
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
686 --framework-path=${ORTHANC_ROOT}/Core
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
687 ${LIBICU_RESOURCES}
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
688 ${DCMTK_DICTIONARIES}
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
689 )
052dc48c15be don't generate embedded resources if not needed
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4034
diff changeset
690 endif()
4030
100fbe970762 DANGEROUS commit: removing HAS_EMBEDDED_RESOURCES
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4026
diff changeset
691
100fbe970762 DANGEROUS commit: removing HAS_EMBEDDED_RESOURCES
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 4026
diff changeset
692
2390
cf0eb76c5e81 fix precompiled headers
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2388
diff changeset
693 set(ORTHANC_CORE_SOURCES
cf0eb76c5e81 fix precompiled headers
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2388
diff changeset
694 ${ORTHANC_CORE_SOURCES_INTERNAL}
cf0eb76c5e81 fix precompiled headers
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2388
diff changeset
695 ${ORTHANC_CORE_SOURCES_DEPENDENCIES}
2388
50cde8246542 CMake to build the Orthanc framework without the Orthanc server
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
696 )
2391
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
697
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
698 if (ENABLE_DCMTK)
2397
98c2a9c2c0fc automated inclusion of DICOM dictionaries
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2396
diff changeset
699 list(APPEND ORTHANC_DICOM_SOURCES_DEPENDENCIES
2391
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
700 ${DCMTK_SOURCES}
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
701 )
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
702
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
703 set(ORTHANC_DICOM_SOURCES
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
704 ${ORTHANC_DICOM_SOURCES_INTERNAL}
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
705 ${ORTHANC_DICOM_SOURCES_DEPENDENCIES}
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
706 )
233d6eeef799 fix pch
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 2390
diff changeset
707 endif()