comparison Resources/CMake/DcmtkConfiguration.cmake @ 1635:0844a4bcb0ad dcmtk-3.6.1

integration mainline->dcmtk
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 23 Sep 2015 09:59:12 +0200
parents b7dfb048b2f3 c095b0ddeea6
children dfbde7c3fe19
comparison
equal deleted inserted replaced
1633:b7dfb048b2f3 1635:0844a4bcb0ad
13 endif() 13 endif()
14 14
15 15
16 if (STATIC_BUILD OR NOT USE_SYSTEM_DCMTK) 16 if (STATIC_BUILD OR NOT USE_SYSTEM_DCMTK)
17 SET(DCMTK_VERSION_NUMBER 361) 17 SET(DCMTK_VERSION_NUMBER 361)
18 set(DCMTK_PACKAGE_VERSION "3.6.1")
18 SET(DCMTK_SOURCES_DIR ${CMAKE_BINARY_DIR}/dcmtk-3.6.1_20150629) 19 SET(DCMTK_SOURCES_DIR ${CMAKE_BINARY_DIR}/dcmtk-3.6.1_20150629)
19 SET(DCMTK_URL "http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/dcmtk-3.6.1_20150629.tar.gz") 20 SET(DCMTK_URL "http://www.montefiore.ulg.ac.be/~jodogne/Orthanc/ThirdPartyDownloads/dcmtk-3.6.1_20150629.zip")
20 SET(DCMTK_MD5 "2faf73786fc638ae05fef0103cce0eea") 21 SET(DCMTK_MD5 "219ad631b82031806147e4abbfba4fa4")
21 22
22 if (IS_DIRECTORY "${DCMTK_SOURCES_DIR}") 23 if (IS_DIRECTORY "${DCMTK_SOURCES_DIR}")
23 set(FirstRun OFF) 24 set(FirstRun OFF)
24 else() 25 else()
25 set(FirstRun ON) 26 set(FirstRun ON)
36 DownloadPackage(${DCMTK_MD5} ${DCMTK_URL} "${DCMTK_SOURCES_DIR}") 37 DownloadPackage(${DCMTK_MD5} ${DCMTK_URL} "${DCMTK_SOURCES_DIR}")
37 38
38 IF (CMAKE_CROSSCOMPILING) 39 IF (CMAKE_CROSSCOMPILING)
39 SET(C_CHAR_UNSIGNED 1 CACHE INTERNAL "Whether char is unsigned.") 40 SET(C_CHAR_UNSIGNED 1 CACHE INTERNAL "Whether char is unsigned.")
40 ENDIF() 41 ENDIF()
41 SET(DCMTK_SOURCE_DIR ${CMAKE_BINARY_DIR}/dcmtk-3.6.1) 42 SET(DCMTK_SOURCE_DIR ${DCMTK_SOURCES_DIR})
42 include(${DCMTK_SOURCES_DIR}/CMake/CheckFunctionWithHeaderExists.cmake) 43 include(${DCMTK_SOURCES_DIR}/CMake/CheckFunctionWithHeaderExists.cmake)
43 include(${DCMTK_SOURCES_DIR}/CMake/GenerateDCMTKConfigure.cmake) 44 include(${DCMTK_SOURCES_DIR}/CMake/GenerateDCMTKConfigure.cmake)
44 45
45 if ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase") 46 if ("${CMAKE_SYSTEM_VERSION}" STREQUAL "LinuxStandardBase")
46 set(HAVE_SSTREAM 1) 47 set(HAVE_SSTREAM 1)
53 set(HAVE_PROTOTYPE_ACCEPT 1) 54 set(HAVE_PROTOTYPE_ACCEPT 1)
54 set(HAVE_PROTOTYPE_SETSOCKNAME 1) 55 set(HAVE_PROTOTYPE_SETSOCKNAME 1)
55 set(HAVE_PROTOTYPE_GETSOCKNAME 1) 56 set(HAVE_PROTOTYPE_GETSOCKNAME 1)
56 endif() 57 endif()
57 58
58 set(DCMTK_PACKAGE_VERSION "3.6.1")
59 set(DCMTK_PACKAGE_VERSION_SUFFIX "") 59 set(DCMTK_PACKAGE_VERSION_SUFFIX "")
60 set(DCMTK_PACKAGE_VERSION_NUMBER 360) 60 set(DCMTK_PACKAGE_VERSION_NUMBER ${DCMTK_VERSION_NUMBER})
61 61
62 CONFIGURE_FILE( 62 CONFIGURE_FILE(
63 ${DCMTK_SOURCES_DIR}/CMake/osconfig.h.in 63 ${DCMTK_SOURCES_DIR}/CMake/osconfig.h.in
64 ${DCMTK_SOURCES_DIR}/config/include/dcmtk/config/osconfig.h) 64 ${DCMTK_SOURCES_DIR}/config/include/dcmtk/config/osconfig.h)
65 65
126 ${DCMTK_SOURCES_DIR}/dcmdata/libsrc/dcdictbi.cc 126 ${DCMTK_SOURCES_DIR}/dcmdata/libsrc/dcdictbi.cc
127 ) 127 )
128 128
129 #set_source_files_properties(${DCMTK_SOURCES} 129 #set_source_files_properties(${DCMTK_SOURCES}
130 # PROPERTIES COMPILE_DEFINITIONS 130 # PROPERTIES COMPILE_DEFINITIONS
131 # "PACKAGE_VERSION=\"3.6.1\";PACKAGE_VERSION_NUMBER=\"360\"") 131 # "PACKAGE_VERSION=\"3.6.1\";PACKAGE_VERSION_NUMBER=\"${DCMTK_VERSION_NUMBER}\"")
132 132
133 # This fixes crashes related to the destruction of the DCMTK OFLogger 133 # This fixes crashes related to the destruction of the DCMTK OFLogger
134 # http://support.dcmtk.org/docs-snapshot/file_macros.html 134 # http://support.dcmtk.org/docs-snapshot/file_macros.html
135 add_definitions( 135 add_definitions(
136 -DLOG4CPLUS_DISABLE_FATAL=1 136 -DLOG4CPLUS_DISABLE_FATAL=1
137 -DDCMTK_VERSION_NUMBER=360 137 -DDCMTK_VERSION_NUMBER=${DCMTK_VERSION_NUMBER}
138 ) 138 )
139 139
140 include_directories( 140 include_directories(
141 #${DCMTK_SOURCES_DIR} 141 #${DCMTK_SOURCES_DIR}
142 ${DCMTK_SOURCES_DIR}/config/include 142 ${DCMTK_SOURCES_DIR}/config/include