Computer Assisted Medical Intervention Tool Kit  version 5.2
CamiTKCommunityEditionPackaging.h
Go to the documentation of this file.
1 
56 
58 string(TOLOWER ${CAMITK_PROJECT_NAME} CPACK_PACKAGE_NAME)
59 set(CPACK_PACKAGE_VERSION_MAJOR ${CAMITK_VERSION_MAJOR})
60 set(CPACK_PACKAGE_VERSION_MINOR ${CAMITK_VERSION_MINOR})
61 set(CPACK_PACKAGE_VERSION_PATCH ${CAMITK_VERSION_PATCH})
62 set(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
63 string(TOLOWER "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}-${CAMITK_VERSION_NICKNAME}-${LSB_DISTRIB}_${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_FILE_NAME)
64 
65 set(CPACK_PACKAGE_VENDOR "Univ. Grenoble Alpes, CNRS, TIMC-IMAG UMR 5525")
67 set(CPACK_PACKAGE_CONTACT "http://camitk.imag.fr")
68 set(CPACK_DEBIAN_PACKAGE_MAINTAINER "Emmanuel Promayon <Emmanuel.Promayon@univ-grenoble-alpes.fr>")
69 
70 set(CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/README")
72 set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/COPYRIGHT")
73 
74 set(CPACK_PACKAGE_EXECUTABLES "camitk-imp" "camitk-imp" "camitk-actionstatemachine" "camitk-actionstatemachine")
76 
77 set(CPACK_PACKAGE_DESCRIPTION "CamiTK stands for Computer Assisted Medical Intervention Tool Kit and aims at providing an easy way to protype medical applications")
79 set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "CamiTK stands for Computer Assisted Medical Intervention Tool Kit and aims at providing an easy way to protype medical applications. CamiTK functionnalities are extendable thanks to plugins. This package includes the IMP application with main plugins that allow users to interact with medical images (2D, 3D), process them and simulate biomechanichal deformations. It also includes the actionstatemachine application that allows user to easily run a pipelines of algorithms on images.")
80 
81 set(CPACK_SOURCE_IGNORE_FILES
83 "~$"
84 "/CVS/"
85 "tags"
86 "/\\\\.svn/"
87 "/\\\\.git/"
88 "/kdev4$/"
89 "/build/"
90 "\\\\.kdevses$"
91 "\\\\.kdev4$"
92 "\\\\.tmp$"
93 "\\\\.tmp.save$"
94 "\\\\.kdevelop\\\\.pcs$"
95 ".DS_Store"
96 ${CPACK_SOURCE_IGNORE_FILES}
97 )
98 
99 set(CPACK_SOURCE_GENERATOR "TGZ" "ZIP" )
100 
101 if(CMAKE_SIZEOF_VOID_P EQUAL 8)
104  set(WIN64 TRUE)
105 else()
106  set(WIN64 FALSE)
107 endif()
108 
109 
110 if (PACKAGING_NSIS AND UNIX AND NOT WIN32)
114 
118 
119  message(STATUS "Packaging CamiTK for UNIX systems")
121  execute_process(COMMAND uname -m OUTPUT_VARIABLE CPACK_PACKAGE_ARCHITECTURE)
122  string(STRIP "${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_ARCHITECTURE)
124  execute_process(COMMAND lsb_release -is OUTPUT_VARIABLE LSB_ID)
125  execute_process(COMMAND lsb_release -rs OUTPUT_VARIABLE LSB_RELEASE)
126  string(STRIP "${LSB_ID}" LSB_ID)
127  string(STRIP "${LSB_RELEASE}" LSB_RELEASE)
128  set(LSB_DISTRIB "${LSB_ID}${LSB_RELEASE}")
129  if(NOT LSB_DISTRIB)
130  set(LSB_DISTRIB "unix")
131  endif(NOT LSB_DISTRIB)
132  message(STATUS "Packager architecture : ${LSB_DISTRIB}")
133 
134 
135  set(CPACK_DEBIAN_PACKAGE_SECTION "science")
136 
137 
138  find_program(DPKG
139  NAMES dpkg-deb
140  PATHS "/usr/bin"
141  )
142  if ( DPKG )
143  get_filename_component(DPKG_PATH ${DPKG} ABSOLUTE)
144  message(STATUS "Packaging deb using ${DPKG_PATH}: OK")
145  set(DPKG_FOUND "YES")
146  else()
147  set(DPKG_FOUND "NO")
148  endif()
149 
150 
151  find_package(ITK REQUIRED)
152  include(${ITK_USE_FILE})
153 
155  set(CPACK_GENERATOR "DEB" "RPM")
156 
157 
158  if ("${LSB_DISTRIB}" MATCHES "Ubuntu|Debian")
159 
161  if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "i[3-6]86")
162  set(CPACK_PACKAGE_ARCHITECTURE i386)
163  endif()
164  if("${CPACK_PACKAGE_ARCHITECTURE}" MATCHES "x86_64")
165  set(CPACK_PACKAGE_ARCHITECTURE amd64)
166  endif()
168 
172  set(CPACK_SET_DESTDIR TRUE)
173  set(CPACK_PACKAGING_INSTALL_PREFIX "/usr")
174  set(CPACK_PACKAGE_DEFAULT_LOCATION "/usr")
175 
176 
177 
180  if("${LSB_DISTRIB}" MATCHES "Ubuntu12.04"
181  OR "${LSB_DISTRIB}" MATCHES "Ubuntu12.04.1"
182  OR "${LSB_DISTRIB}" MATCHES "Ubuntu12.10"
183  OR "${LSB_DISTRIB}" MATCHES "Ubuntu13.04"
184  OR "${LSB_DISTRIB}" MATCHES "Ubuntu13.10"
185  )
187  set(LSB_DISTRIB "Ubuntu12.04to13.10")
188  set(CPACK_DEBIAN_PACKAGE_DEPENDS "cmake, libvtk5-dev (>= 5.8), libqt4-dev, libvtk5-qt4-dev (>= 5.8), xsdcxx, libinsighttoolkit3-dev (>= 3.20), libxerces-c-dev, libxml2-dev, libgdcm2-dev, libfftw3-dev, libqtwebkit-dev | libqt4-dev (<< 4.7), libvtkgdcm2-dev,doxygen, graphviz")
189  endif()
190 
191 
192  if ("${LSB_DISTRIB}" MATCHES "Debian7.*")
193  set(LSB_DISTRIB "Debian-7.x-Wheezy")
194  set(CPACK_DEBIAN_PACKAGE_DEPENDS "libqt4-dev (>= 4:4.8), libqtwebkit4 (>= 2), libqtwebkit-dev (>= 2), libvtk5.8 (>= 5.8.0), libvtk5-dev (>= 5.8.0), libvtk5.8-qt4 (>= 5.8.0), libvtk5-qt4-dev (>= 5.8.0), libinsighttoolkit3-dev (>= 3.20.1), vtk-doc (>= 5.8.0), tcl-vtk (>= 5.8.0), libinsighttoolkit3.20 (>= 3.20.1), libtiff4-dev (>= 3.9), libopenjpeg-dev (>= 1.3), libxml2 (>= 2.7.8), libxml2-dev (>= 2.7.8), xsdcxx (>= 3.3.0), libxerces-c-dev (>= 3.1.1), libgdcm2.2 (>= 2), libgdcm2-dev (>= 2), libvtkgdcm2.2 (>= 2), libvtkgdcm2-dev (>= 2)")
195  endif()
196 
197  if(NOT CPACK_DEBIAN_PACKAGE_DEPENDS)
198  message(STATUS "Packaging for ${LSB_DISTRIB} not supported yet.\n")
199  endif()
200 
201  endif()
202 
203 
204  string(TOLOWER "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}-${LSB_DISTRIB}_${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_FILE_NAME)
205 
206 endif()
207 
208 
209 if(WIN32 AND MSVC AND PACKAGING_NSIS)
213 
215  find_program(MAKENSIS makensis.exe)
216  if(MAKENSIS)
217  message(STATUS "NSIS Packaging using ${MAKENSIS}")
218  else()
219  message(FATAL_ERROR "NSIS executable (makensis.exe) is not installed or not in the system path. Please fix this problem for packaging.")
220  endif()
221 
222 
223  if(WIN64)
224  set(CPACK_PACKAGE_ARCHITECTURE amd64)
225  else()
226  set(CPACK_PACKAGE_ARCHITECTURE i386)
227  endif()
228  string(TOLOWER "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}-${CAMITK_VERSION_NICKNAME}_${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_FILE_NAME)
229 
230  # get the root installation dir of Qt5
231  # Qt5_DIR
232  string(REGEX REPLACE "(.*)/lib/.*" "\\1" QT5_ROOT_DIR "${Qt5_DIR}")
233  # DEBUG
234  # message(STATUS "==========***************************================ QT5_ROOT_DIR = ${QT5_ROOT_DIR}")
235  find_file(QT5_PLATFORM_FILE
236  qwindows.dll
237  PATH_SUFFIXES plugins/platforms
238  PATHS ${Qt5_DIR}
239  )
240  # DEBUG
241  # message(STATUS "==========***************************================ QT5_PLATFORM_FILE = ${QT5_PLATFORM_FILE}")
242 
243  if(NOT QT5_PLATFORM_FILE)
244  message(WARNING "Cannot find qwindows.dll: running target 'camitk-package' will result in a buggy NSIS user package")
245  else()
246  # Instead of putting the same value twice into different variable it would be a good idea to use this mecanism
247  # to fill all libraries variables below (as seen in CamiTK meeting)
248  set(CPACK_QT5_FILE_TO_INSTALL ${QT5_PLATFORM_FILE})
249  endif()
250 
251  message(STATUS "Packaging CamiTK for Windows: ${CPACK_PACKAGE_FILE_NAME}")
252 
253  if(WIN64)
255  set(QT_PACKAGE_LIBRARIES
256  c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5CORE.DLL
257  c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5GUI.DLL
258  c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5OPENGL.DLL
259  c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5WIDGETS.DLL
260  c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5XML.DLL
261  )
262 
263  set(QT_MANDATORY_WIN_RT_DLL
264  ${QT5_PLATFORM_FILE}
265  )
266 
268  set(VTK_PACKAGE_LIBRARIES
269  c:/dev/vtk/6.3/bin/VTKALGLIB-6.3.DLL
270  c:/dev/vtk/6.3/bin/VTKCOMMONCOLOR-6.3.DLL
271  c:/dev/vtk/6.3/bin/VTKCOMMONCOMPUTATIONALGEOMETRY-6.3.DLL
272  c:/dev/vtk/6.3/bin/VTKCOMMONDATAMODEL-6.3.DLL
273  c:/dev/vtk/6.3/bin/VTKCOMMONEXECUTIONMODEL-6.3.DLL
274  c:/dev/vtk/6.3/bin/VTKCOMMONMATH-6.3.DLL
275  c:/dev/vtk/6.3/bin/VTKCOMMONMISC-6.3.DLL
276  c:/dev/vtk/6.3/bin/VTKCOMMONSYSTEM-6.3.DLL
277  c:/dev/vtk/6.3/bin/VTKCOMMONTRANSFORMS-6.3.DLL
278  c:/dev/vtk/6.3/bin/VTKDICOMPARSER-6.3.DLL
279  c:/dev/vtk/6.3/bin/VTKFILTERSCORE-6.3.DLL
280  c:/dev/vtk/6.3/bin/VTKFILTERSEXTRACTION-6.3.DLL
281  c:/dev/vtk/6.3/bin/VTKFILTERSGENERAL-6.3.DLL
282  c:/dev/vtk/6.3/bin/VTKFILTERSGEOMETRY-6.3.DLL
283  c:/dev/vtk/6.3/bin/VTKFILTERSHYBRID-6.3.DLL
284  c:/dev/vtk/6.3/bin/VTKFILTERSMODELING-6.3.DLL
285  c:/dev/vtk/6.3/bin/VTKFILTERSSOURCES-6.3.DLL
286  c:/dev/vtk/6.3/bin/VTKFILTERSSTATISTICS-6.3.DLL
287  c:/dev/vtk/6.3/bin/VTKFREETYPE-6.3.DLL
288  c:/dev/vtk/6.3/bin/VTKFTGL-6.3.DLL
289  c:/dev/vtk/6.3/bin/VTKGL2PS-6.3.DLL
290  c:/dev/vtk/6.3/bin/VTKGUISUPPORTQT-6.3.DLL
291  c:/dev/vtk/6.3/bin/VTKGUISUPPORTQTOPENGL-6.3.DLL
292  c:/dev/vtk/6.3/bin/VTKIMAGINGCOLOR-6.3.DLL
293  c:/dev/vtk/6.3/bin/VTKIMAGINGFOURIER-6.3.DLL
294  c:/dev/vtk/6.3/bin/VTKIMAGINGGENERAL-6.3.DLL
295  c:/dev/vtk/6.3/bin/VTKIMAGINGHYBRID-6.3.DLL
296  c:/dev/vtk/6.3/bin/VTKINTERACTIONWIDGETS-6.3.DLL
297  c:/dev/vtk/6.3/bin/VTKIOCORE-6.3.DLL
298  c:/dev/vtk/6.3/bin/VTKIOEXPORT-6.3.DLL
299  c:/dev/vtk/6.3/bin/VTKJPEG-6.3.DLL
300  c:/dev/vtk/6.3/bin/VTKMETAIO-6.3.DLL
301  c:/dev/vtk/6.3/bin/VTKPNG-6.3.DLL
302  c:/dev/vtk/6.3/bin/VTKRENDERINGANNOTATION-6.3.DLL
303  c:/dev/vtk/6.3/bin/VTKRENDERINGCONTEXT2D-6.3.DLL
304  c:/dev/vtk/6.3/bin/VTKRENDERINGCONTEXTOPENGL-6.3.DLL
305  c:/dev/vtk/6.3/bin/VTKRENDERINGGL2PS-6.3.DLL
306  c:/dev/vtk/6.3/bin/VTKRENDERINGLABEL-6.3.DLL
307  c:/dev/vtk/6.3/bin/VTKRENDERINGVOLUME-6.3.DLL
308  c:/dev/vtk/6.3/bin/VTKRENDERINGVOLUMEOPENGL-6.3.DLL
309  c:/dev/vtk/6.3/bin/VTKTIFF-6.3.DLL
310  c:/dev/vtk/6.3/bin/VTKZLIB-6.3.DLL
311  c:/dev/vtk/6.3/bin/vtkFiltersVerdict-6.3.dll
312  c:/dev/vtk/6.3/bin/vtkImagingMath-6.3.dll
313  c:/dev/vtk/6.3/bin/vtkImagingStencil-6.3.dll
314  c:/dev/vtk/6.3/bin/vtkIOGeometry-6.3.dll
315  c:/dev/vtk/6.3/bin/vtkIOImport-6.3.dll
316  c:/dev/vtk/6.3/bin/vtkIOLegacy-6.3.dll
317  c:/dev/vtk/6.3/bin/vtkverdict-6.3.dll
318  )
319 
320 
321  set(ITK_PACKAGE_LIBRARIES
322  C:/dev/ITK/4.9/bin/ITKCommon-4.9.dll
323  C:/dev/ITK/4.9/bin/ITKIOBioRad-4.9.dll
324  C:/dev/ITK/4.9/bin/ITKIOBMP-4.9.dll
325  C:/dev/ITK/4.9/bin/ITKIOGDCM-4.9.dll
326  C:/dev/ITK/4.9/bin/ITKIOGE-4.9.dll
327  C:/dev/ITK/4.9/bin/ITKIOGIPL-4.9.dll
328  C:/dev/ITK/4.9/bin/ITKIOHDF5-4.9.dll
329  C:/dev/ITK/4.9/bin/ITKIOImageBase-4.9.dll
330  C:/dev/ITK/4.9/bin/ITKIOIPL-4.9.dll
331  C:/dev/ITK/4.9/bin/ITKIOJPEG-4.9.dll
332  C:/dev/ITK/4.9/bin/ITKIOLSM-4.9.dll
333  C:/dev/ITK/4.9/bin/ITKIOMeta-4.9.dll
334  C:/dev/ITK/4.9/bin/ITKIOMRC-4.9.dll
335  C:/dev/ITK/4.9/bin/ITKIONIFTI-4.9.dll
336  C:/dev/ITK/4.9/bin/ITKIONRRD-4.9.dll
337  C:/dev/ITK/4.9/bin/ITKIOPNG-4.9.dll
338  C:/dev/ITK/4.9/bin/ITKIOStimulate-4.9.dll
339  C:/dev/ITK/4.9/bin/ITKIOTIFF-4.9.dll
340  C:/dev/ITK/4.9/bin/ITKIOVTK-4.9.dll
341  )
342 
343 
344  set(GDCM_PACKAGE_LIBRARIES
345  c:/dev/gdcm/2.6.3/bin/VTKCOMMONCORE-6.3.DLL
346  c:/dev/gdcm/2.6.3/bin/VTKIMAGINGCORE-6.3.DLL
347  c:/dev/gdcm/2.6.3/bin/VTKIMAGINGSOURCES-6.3.DLL
348  c:/dev/gdcm/2.6.3/bin/VTKINTERACTIONSTYLE-6.3.DLL
349  c:/dev/gdcm/2.6.3/bin/VTKIOIMAGE-6.3.DLL
350  c:/dev/gdcm/2.6.3/bin/VTKRENDERINGCORE-6.3.DLL
351  c:/dev/gdcm/2.6.3/bin/VTKRENDERINGFREETYPE-6.3.DLL
352  c:/dev/gdcm/2.6.3/bin/VTKRENDERINGOPENGL-6.3.DLL
353  c:/dev/gdcm/2.6.3/bin/VTKSYS-6.3.DLL
354  c:/dev/gdcm/2.6.3/bin/gdcmcharls.dll
355  c:/dev/gdcm/2.6.3/bin/gdcmCommon.dll
356  c:/dev/gdcm/2.6.3/bin/gdcmDICT.dll
357  c:/dev/gdcm/2.6.3/bin/gdcmDSED.dll
358  c:/dev/gdcm/2.6.3/bin/gdcmexpat.dll
359  c:/dev/gdcm/2.6.3/bin/gdcmgetopt.dll
360  c:/dev/gdcm/2.6.3/bin/gdcmIOD.dll
361  c:/dev/gdcm/2.6.3/bin/gdcmjpeg8.dll
362  c:/dev/gdcm/2.6.3/bin/gdcmjpeg12.dll
363  c:/dev/gdcm/2.6.3/bin/gdcmjpeg16.dll
364  c:/dev/gdcm/2.6.3/bin/gdcmMSFF.dll
365  c:/dev/gdcm/2.6.3/bin/gdcmopenjpeg.dll
366  c:/dev/gdcm/2.6.3/bin/gdcmjpeg16.dll
367  c:/dev/gdcm/2.6.3/bin/gdcmzlib.dll
368  c:/dev/gdcm/2.6.3/bin/vtkgdcm.dll
369  )
370 
371  set(XERCES_C_PACKAGE_LIBRARIES
372  C:/dev/xerces-c/3.1.1/bin/xerces-c_3_1.dll
373  )
374 
375  else()
376 
378  set(QT_PACKAGE_LIRABRIES
379  C:/dev_x86/Qt/4.8.5/bin/QtCore4.dll
380  C:/dev_x86/Qt/4.8.5/bin/QtGui4.dll
381  C:/dev_x86/Qt/4.8.5/bin/QtSvg4.dll
382  C:/dev_x86/Qt/4.8.5/bin/QtXml4.dll
383  C:/dev_x86/Qt/4.8.5/bin/QtNetwork4.dll
384  C:/dev_x86/Qt/4.8.5/bin/QtSql4.dll
385  C:/dev_x86/Qt/4.8.5/bin/QtWebKit4.dll
386  )
387 
388 
390  set(VTK_PACKAGE_LIBRARIES
391  C:/dev_x86/VTK/5.10.1/bin/QVTK.dll
392  C:/dev_x86/VTK/5.10.1/bin/vtkCommon.dll
393  C:/dev_x86/VTK/5.10.1/bin/vtksys.dll
394  C:/dev_x86/VTK/5.10.1/bin/vtkFiltering.dll
395  C:/dev_x86/VTK/5.10.1/bin/vtkGraphics.dll
396  C:/dev_x86/VTK/5.10.1/bin/vtkHybrid.dll
397  C:/dev_x86/VTK/5.10.1/bin/vtkIO.dll
398  C:/dev_x86/VTK/5.10.1/bin/vtkImaging.dll
399  C:/dev_x86/VTK/5.10.1/bin/vtkRendering.dll
400  C:/dev_x86/VTK/5.10.1/bin/vtkVolumeRendering.dll
401  C:/dev_x86/VTK/5.10.1/bin/vtkverdict.dll
402  C:/dev_x86/VTK/5.10.1/bin/vtkDICOMParser.dll
403  C:/dev_x86/VTK/5.10.1/bin/vtkNetCDF.dll
404  C:/dev_x86/VTK/5.10.1/bin/vtkNetCDF_cxx.dll
405  C:/dev_x86/VTK/5.10.1/bin/vtkexpat.dll
406  C:/dev_x86/VTK/5.10.1/bin/vtkjpeg.dll
407  C:/dev_x86/VTK/5.10.1/bin/vtkmetaio.dll
408  C:/dev_x86/VTK/5.10.1/bin/vtkpng.dll
409  C:/dev_x86/VTK/5.10.1/bin/vtktiff.dll
410  C:/dev_x86/VTK/5.10.1/bin/vtkzlib.dll
411  C:/dev_x86/VTK/5.10.1/bin/vtkInfovis.dll
412  C:/dev_x86/VTK/5.10.1/bin/vtkfreetype.dll
413  C:/dev_x86/VTK/5.10.1/bin/vtkftgl.dll
414  C:/dev_x86/VTK/5.10.1/bin/vtkalglib.dll
415  C:/dev_x86/VTK/5.10.1/bin/vtklibxml2.dll
416  C:/dev_x86/VTK/5.10.1/bin/vtkViews.dll
417  C:/dev_x86/VTK/5.10.1/bin/vtkexoIIc.dll
418  C:/dev_x86/VTK/5.10.1/bin/vtkWidgets.dll
419  C:/dev_x86/VTK/5.10.1/bin/vtkhdf5.dll
420  C:/dev_x86/VTK/5.10.1/bin/vtkhdf5_hl.dll
421  C:/dev_x86/VTK/5.10.1/bin/LSDyna.dll
422  )
423 
424 
425  set(ITK_PACKAGE_LIBRARIES
426  C:/dev_x86/ITK/4.3.2/bin/ITKCommon-4.3.dll
427  )
428 
429 
430  set(GDCM_PACKAGE_LIBRARIES
431  C:/dev_x86/gdcm/2.2.5/bin/vtkgdcm.dll
432  C:/dev_x86/gdcm/2.2.5/bin/gdcmcommon.dll
433  C:/dev_x86/gdcm/2.2.5/bin/gdcmcharls.dll
434  C:/dev_x86/gdcm/2.2.5/bin/gdcmdict.dll
435  C:/dev_x86/gdcm/2.2.5/bin/gdcmdsed.dll
436  C:/dev_x86/gdcm/2.2.5/bin/gdcmexpat.dll
437  C:/dev_x86/gdcm/2.2.5/bin/gdcmiod.dll
438  C:/dev_x86/gdcm/2.2.5/bin/gdcmjpeg12.dll
439  C:/dev_x86/gdcm/2.2.5/bin/gdcmjpeg16.dll
440  C:/dev_x86/gdcm/2.2.5/bin/gdcmjpeg8.dll
441  C:/dev_x86/gdcm/2.2.5/bin/gdcmmsff.dll
442  C:/dev_x86/gdcm/2.2.5/bin/gdcmopenjpeg.dll
443  C:/dev_x86/gdcm/2.2.5/bin/gdcmzlib.dll
444  C:/dev_x86/gdcm/2.2.5/bin/gdcmmsff.dll
445  )
446 
447  set(LIBXML2_PACKAGE_LIBRARIES
448  C:/dev_x86/libxml2/2.7.8/bin/iconv.dll
449  C:/dev_x86/libxml2/2.7.8/bin/libxml2.dll
450  C:/dev_x86/libxml2/2.7.8/bin/zlib1.dll
451  )
452 
453  set(XERCES_C_PACKAGE_LIBRARIES
454  C:/dev_x86/xerces-c/3.1.1/bin/xerces-c_3_1.dll
455  )
456  endif()
457 
458 
459  set(CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS
460  ${QT_PACKAGE_LIBRARIES}
461  ${QT_MANDATORY_WIN_RT_DLL}
462  ${VTK_PACKAGE_LIBRARIES}
463  ${ITK_PACKAGE_LIBRARIES}
464  ${GDCM_PACKAGE_LIBRARIES}
465  ${LIBXML2_PACKAGE_LIBRARIES}
466  ${XERCES_C_PACKAGE_LIBRARIES}
467  )
468 
470  if(NOT DEFINED CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS)
471  SET(CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS ON)
472  endif()
473 
474 
475  include(InstallRequiredSystemLibraries)
476 
477 
478  set(CAMITK_PACKAGE_ICON "${CMAKE_CURRENT_SOURCE_DIR}\\\\sdk\\\\libraries\\\\core\\\\resources\\\\appIcon.ico")
479  set(CPACK_PACKAGE_ICON ${CAMITK_PACKAGE_ICON})
480  set(CPACK_NSIS_MUI_ICON ${CAMITK_PACKAGE_ICON})
481  set(CPACK_NSIS_MUI_UNIICON ${CAMITK_PACKAGE_ICON})
482 
484  set(CPACK_NSIS_EXTRA_INSTALL_COMMANDS "CreateShortCut \\\"$DESKTOP\\\\${CAMITK_PROJECT_NAME}-imp.lnk\\\" \\\"$INSTDIR\\\\bin\\\\camitk-imp.exe\\\"")
485 
486 
487  set(CPACK_NSIS_EXTRA_UNINSTALL_COMMANDS "Delete \\\"$DESKTOP\\\\${CAMITK_PROJECT_NAME}-imp.lnk\\\"")
488 
489 
490  set(CPACK_NSIS_DISPLAY_NAME "CamiTK ${CAMITK_VERSION_MAJOR}.${CAMITK_VERSION_MINOR}.${CAMITK_VERSION_PATCH}")
491  set(CPACK_NSIS_INSTALLED_ICON_NAME ${CAMITK_PROJECT_NAME})
492 
493  set(CPACK_PACKAGE_INSTALL_DIRECTORY ${CAMITK_PROJECT_NAME})
494  set(CPACK_NSIS_HELP_LINK "http:\\\\\\\\camitk.imag.fr")
495  set(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\camitk.imag.fr")
496  set(CPACK_NSIS_CONTACT ${CPACK_PACKAGE_CONTACT})
497 
498 endif()
499 
500 if(PACKAGING_NSIS AND APPLE)
505  set(CPACK_GENERATOR "PackageMaker")
507  set(CPACK_COMPONENT_LIBRARIES_HIDDEN TRUE)
509  set(MACOSX_BUNDLE_BUNDLE_NAME ${CPACK_PACKAGE_NAME})
510  set(MACOSX_BUNDLE_BUNDLE_VERSION ${PROJECT_VERSION})
511  set(MACOSX_BUNDLE_SHORT_VERSION_STRING ${PROJECT_VERSION})
512  set(MACOSX_BUNDLE_LONG_VERSION_STRING "Version ${PROJECT_VERSION}")
513 endif()
514 
515 
516 
517 set(CPACK_RESOURCE_FILE_README ${CMAKE_CURRENT_SOURCE_DIR}/README.md)
519 include(CPack)
520 
521 cpack_add_component_group(SDK
523  DISPLAY_NAME "CamiTK SDK"
524  DESCRIPTION "The CamiTK SDK features the core and basics extensions. CamiTK installation requires at least the SDK"
525  BOLD_TITLE
526  )
527 cpack_add_component_group(CEP_IMAGING
528  DISPLAY_NAME "CEP Imaging"
529  DESCRIPTION "The CamiTK Extension Project IMAGING contains image processing extensions. Those extensions are optional."
530  )
531 cpack_add_component_group(CEP_MODELING
532  DISPLAY_NAME "CEP Modeling"
533  DESCRIPTION "The CamiTK Extension Project MODELING contains biomechanical extensions. Those extensions are optional."
534  )
535 
536 
543 add_custom_target(camitk-ce-package-source
544  COMMAND ${CMAKE_COMMAND}
545  -E copy ${CMAKE_CURRENT_BINARY_DIR}/CamiTKPackageVersion.h
546  ${CMAKE_CURRENT_SOURCE_DIR}/sdk/libraries/core/CamiTKVersion.h
547  COMMAND ${CMAKE_COMMAND}
548  --build ${CMAKE_BINARY_DIR}
549  --target package_source
550  COMMAND ${CMAKE_COMMAND}
551  -E remove -f ${CMAKE_CURRENT_SOURCE_DIR}/sdk/libraries/core/CamiTKVersion.h
552 )
553 
557 add_custom_target(camitk-ce-NSIS-Windows-package
558  COMMAND ${CMAKE_COMMAND}
559  -E copy ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h
560  ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h-backup
561  COMMAND ${CMAKE_COMMAND}
562  -E copy ${CMAKE_CURRENT_BINARY_DIR}/CamiTKPackageVersion.h
563  ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h
564  COMMAND ${CMAKE_COMMAND}
565  --build ${CMAKE_BINARY_DIR}
566  --target PACKAGE --config Release
567  COMMAND ${CMAKE_COMMAND}
568  -E copy ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h-backup
569  ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h
570 )
571 
572 end(){)
cmake modules macros camitk test endif() add_custom_target(camitk-ce-iwyu COMMAND $
Definition: CamiTKIncludeWhatYouUse.h:37
iwyu out CACHE PATH Output filename for include what you use set(CMAKE_CXX_INCLUDE_WHAT_YOU_USE ${IWYU_EXECUTABLE}) if(NOT EXISTS $
Definition: CamiTKIncludeWhatYouUse.h:22
get_filename_component(OUTFILE ${CAMITK_TEST_PASS_FILE} NAME) set(CAMITK_TEST_COMMAND_OUTPUT_FILE $
This CMake file run a command that is supposed to produce an output file, and then compare this outpu...
Definition: CamiTKTestCompareFile.h:13
test result execute_process(COMMAND ${CMAKE_COMMAND} -E remove -f ${CAMITK_TEST_COMMAND_FILE} ${CAMITK_TEST_COMMAND_RESULT_FILE} ${CAMITK_TEST_COMMAND_OUTPUT_FILE} ${CAMITK_TEST_PASS_FILE_COMMAND_FILE} ${CAMITK_TEST_PASS_FILE_OUTPUT_FILE} ${CAMITK_TEST_PASS_FILE_RESULT_FILE}) file(WRITE $
Definition: CamiTKTestPassFile.h:21
static void include(QRect &r, const QRect &rect)
Definition: canvas_typed/qtcanvas.cpp:98
camitk_communityedition_packaging()
==================== Source Tar ball ====================
Definition: CamiTKCommunityEditionPackaging.h:55
Definition: Action.cpp:36