Mercurial > hg > orthanc-transfers
comparison CMakeLists.txt @ 14:e1b24c9a9bd8
patch Orthanc 1.5.6
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 04 Mar 2019 16:48:25 +0100 |
parents | df314d38a4e0 |
children | 3eb5ccd37e31 |
comparison
equal
deleted
inserted
replaced
13:df314d38a4e0 | 14:e1b24c9a9bd8 |
---|---|
24 set(ORTHANC_FRAMEWORK_VERSION "mainline") | 24 set(ORTHANC_FRAMEWORK_VERSION "mainline") |
25 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "hg") | 25 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "hg") |
26 else() | 26 else() |
27 set(ORTHANC_FRAMEWORK_VERSION "1.5.6") | 27 set(ORTHANC_FRAMEWORK_VERSION "1.5.6") |
28 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "web") | 28 set(ORTHANC_FRAMEWORK_DEFAULT_SOURCE "web") |
29 | |
30 # diff --new-file -urEb Orthanc-1.5.6.orig/ Orthanc-1.5.6 > orthanc-1.5.6.patch | |
31 set(ORTHANC_FRAMEWORK_PATCH "${CMAKE_SOURCE_DIR}/Resources/Patches/orthanc-1.5.6.patch") | |
29 endif() | 32 endif() |
30 | 33 |
31 | 34 |
32 # Parameters of the build | 35 # Parameters of the build |
33 set(ORTHANC_FRAMEWORK_SOURCE "${ORTHANC_FRAMEWORK_DEFAULT_SOURCE}" CACHE STRING "Source of the Orthanc source code (can be \"hg\", \"archive\", \"web\" or \"path\")") | 36 set(ORTHANC_FRAMEWORK_SOURCE "${ORTHANC_FRAMEWORK_DEFAULT_SOURCE}" CACHE STRING "Source of the Orthanc source code (can be \"hg\", \"archive\", \"web\" or \"path\")") |
51 set(ENABLE_MODULE_DICOM OFF) | 54 set(ENABLE_MODULE_DICOM OFF) |
52 set(ENABLE_ZLIB ON) | 55 set(ENABLE_ZLIB ON) |
53 | 56 |
54 include(${ORTHANC_ROOT}/Resources/CMake/OrthancFrameworkConfiguration.cmake) | 57 include(${ORTHANC_ROOT}/Resources/CMake/OrthancFrameworkConfiguration.cmake) |
55 include_directories(${ORTHANC_ROOT}) | 58 include_directories(${ORTHANC_ROOT}) |
59 | |
60 | |
61 # Possibly patch the Orthanc framework | |
62 if (DEFINED ORTHANC_FRAMEWORK_PATCH AND | |
63 NOT EXISTS "${ORTHANC_ROOT}/patched") | |
64 execute_process( | |
65 COMMAND ${PATCH_EXECUTABLE} -p0 -N -i ${ORTHANC_FRAMEWORK_PATCH} | |
66 WORKING_DIRECTORY ${CMAKE_BINARY_DIR} | |
67 RESULT_VARIABLE Failure | |
68 ) | |
69 | |
70 if (Failure) | |
71 message(FATAL_ERROR "Error while patching a file") | |
72 endif() | |
73 endif() | |
56 | 74 |
57 | 75 |
58 # Check that the Orthanc SDK headers are available | 76 # Check that the Orthanc SDK headers are available |
59 if (STATIC_BUILD OR NOT USE_SYSTEM_ORTHANC_SDK) | 77 if (STATIC_BUILD OR NOT USE_SYSTEM_ORTHANC_SDK) |
60 if (ORTHANC_SDK_VERSION STREQUAL "1.4.2") | 78 if (ORTHANC_SDK_VERSION STREQUAL "1.4.2") |