Commit 90593fe0 authored by Jean-Loup HABERBUSCH's avatar Jean-Loup HABERBUSCH
Browse files

Merge branch 'fix-bug-Windows_Package_User' into develop

# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.
parents b7fa2e05 2179290d
This diff is collapsed.
......@@ -227,82 +227,145 @@ if(WIN32 AND MSVC AND PACKAGING_NSIS)
endif()
string(TOLOWER "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}-${CAMITK_VER_NICKNAME}_${CPACK_PACKAGE_ARCHITECTURE}" CPACK_PACKAGE_FILE_NAME)
# get the root installation dir of Qt5
# Qt5_DIR
string(REGEX REPLACE "(.*)/lib/.*" "\\1" QT5_ROOT_DIR "${Qt5_DIR}")
# DEBUG
# message(STATUS "==========***************************================ QT5_ROOT_DIR = ${QT5_ROOT_DIR}")
find_file(QT5_PLATFORM_FILE
qwindows.dll
PATH_SUFFIXES plugins/platforms
PATHS ${Qt5_DIR}
)
# DEBUG
# message(STATUS "==========***************************================ QT5_PLATFORM_FILE = ${QT5_PLATFORM_FILE}")
if(NOT QT5_PLATFORM_FILE)
message(WARNING "Cannot find qwindows.dll: running target 'camitk_package' will result in a buggy NSIS user package")
else()
# Instead of putting the same value twice into different variable it would be a good idea to use this mecanism
# to fill all libraries variables below (as seen in CamiTK meeting)
set(CPACK_QT5_FILE_TO_INSTALL ${QT5_PLATFORM_FILE})
endif()
message(STATUS "Packaging CamiTK for Windows: ${CPACK_PACKAGE_FILE_NAME}")
if(WIN64) #! 64bits installer
#! Qt libraries
set(QT_PACKAGE_LIRABRIES
C:/dev/Qt/4.8.5/bin/QtCore4.dll
C:/dev/Qt/4.8.5/bin/QtGui4.dll
C:/dev/Qt/4.8.5/bin/QtSvg4.dll
C:/dev/Qt/4.8.5/bin/QtXml4.dll
C:/dev/Qt/4.8.5/bin/QtNetwork4.dll
C:/dev/Qt/4.8.5/bin/QtSql4.dll
C:/dev/Qt/4.8.5/bin/QtWebKit4.dll
set(QT_PACKAGE_LIBRARIES
c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5CORE.DLL
c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5GUI.DLL
c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5OPENGL.DLL
c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5WIDGETS.DLL
c:/dev/qt5.6/5.6/msvc2015_64/bin/QT5XML.DLL
)
set(QT_MANDATORY_WIN_RT_DLL
${QT5_PLATFORM_FILE}
)
#! VTK libraries
set(VTK_PACKAGE_LIBRARIES
C:/dev/VTK/5.10.1/bin/QVTK.dll
C:/dev/VTK/5.10.1/bin/vtkCommon.dll
C:/dev/VTK/5.10.1/bin/vtksys.dll
C:/dev/VTK/5.10.1/bin/vtkFiltering.dll
C:/dev/VTK/5.10.1/bin/vtkGraphics.dll
C:/dev/VTK/5.10.1/bin/vtkHybrid.dll
C:/dev/VTK/5.10.1/bin/vtkIO.dll
C:/dev/VTK/5.10.1/bin/vtkImaging.dll
C:/dev/VTK/5.10.1/bin/vtkRendering.dll
C:/dev/VTK/5.10.1/bin/vtkVolumeRendering.dll
C:/dev/VTK/5.10.1/bin/vtkverdict.dll
C:/dev/VTK/5.10.1/bin/vtkDICOMParser.dll
C:/dev/VTK/5.10.1/bin/vtkNetCDF.dll
C:/dev/VTK/5.10.1/bin/vtkNetCDF_cxx.dll
C:/dev/VTK/5.10.1/bin/vtkexpat.dll
C:/dev/VTK/5.10.1/bin/vtkjpeg.dll
C:/dev/VTK/5.10.1/bin/vtkmetaio.dll
C:/dev/VTK/5.10.1/bin/vtkpng.dll
C:/dev/VTK/5.10.1/bin/vtktiff.dll
C:/dev/VTK/5.10.1/bin/vtkzlib.dll
C:/dev/VTK/5.10.1/bin/vtkInfovis.dll
C:/dev/VTK/5.10.1/bin/vtkfreetype.dll
C:/dev/VTK/5.10.1/bin/vtkftgl.dll
C:/dev/VTK/5.10.1/bin/vtkalglib.dll
C:/dev/VTK/5.10.1/bin/vtklibxml2.dll
C:/dev/VTK/5.10.1/bin/vtkViews.dll
C:/dev/VTK/5.10.1/bin/vtkexoIIc.dll
C:/dev/VTK/5.10.1/bin/vtkWidgets.dll
C:/dev/VTK/5.10.1/bin/vtkhdf5.dll
C:/dev/VTK/5.10.1/bin/vtkhdf5_hl.dll
C:/dev/VTK/5.10.1/bin/LSDyna.dll
c:/dev/vtk/6.3/bin/VTKALGLIB-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONCOLOR-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONCOMPUTATIONALGEOMETRY-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONDATAMODEL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONEXECUTIONMODEL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONMATH-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONMISC-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONSYSTEM-6.3.DLL
c:/dev/vtk/6.3/bin/VTKCOMMONTRANSFORMS-6.3.DLL
c:/dev/vtk/6.3/bin/VTKDICOMPARSER-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSCORE-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSEXTRACTION-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSGENERAL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSGEOMETRY-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSHYBRID-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSMODELING-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSSOURCES-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFILTERSSTATISTICS-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFREETYPE-6.3.DLL
c:/dev/vtk/6.3/bin/VTKFTGL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKGL2PS-6.3.DLL
c:/dev/vtk/6.3/bin/VTKGUISUPPORTQT-6.3.DLL
c:/dev/vtk/6.3/bin/VTKGUISUPPORTQTOPENGL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIMAGINGCOLOR-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIMAGINGFOURIER-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIMAGINGGENERAL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIMAGINGHYBRID-6.3.DLL
c:/dev/vtk/6.3/bin/VTKINTERACTIONWIDGETS-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIOCORE-6.3.DLL
c:/dev/vtk/6.3/bin/VTKIOEXPORT-6.3.DLL
c:/dev/vtk/6.3/bin/VTKJPEG-6.3.DLL
c:/dev/vtk/6.3/bin/VTKMETAIO-6.3.DLL
c:/dev/vtk/6.3/bin/VTKPNG-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGANNOTATION-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGCONTEXT2D-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGCONTEXTOPENGL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGGL2PS-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGLABEL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGVOLUME-6.3.DLL
c:/dev/vtk/6.3/bin/VTKRENDERINGVOLUMEOPENGL-6.3.DLL
c:/dev/vtk/6.3/bin/VTKTIFF-6.3.DLL
c:/dev/vtk/6.3/bin/VTKZLIB-6.3.DLL
c:/dev/vtk/6.3/bin/vtkFiltersVerdict-6.3.dll
c:/dev/vtk/6.3/bin/vtkImagingMath-6.3.dll
c:/dev/vtk/6.3/bin/vtkImagingStencil-6.3.dll
c:/dev/vtk/6.3/bin/vtkIOGeometry-6.3.dll
c:/dev/vtk/6.3/bin/vtkIOImport-6.3.dll
c:/dev/vtk/6.3/bin/vtkIOLegacy-6.3.dll
c:/dev/vtk/6.3/bin/vtkverdict-6.3.dll
)
#!ITK library
set(ITK_PACKAGE_LIBRARIES
C:/dev/ITK/4.3.2/bin/ITKCommon-4.3.dll
C:/dev/ITK/4.9/bin/ITKCommon-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOBioRad-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOBMP-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOGDCM-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOGE-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOGIPL-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOHDF5-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOImageBase-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOIPL-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOJPEG-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOLSM-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOMeta-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOMRC-4.9.dll
C:/dev/ITK/4.9/bin/ITKIONIFTI-4.9.dll
C:/dev/ITK/4.9/bin/ITKIONRRD-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOPNG-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOStimulate-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOTIFF-4.9.dll
C:/dev/ITK/4.9/bin/ITKIOVTK-4.9.dll
)
#! GDCM libraries
set(GDCM_PACKAGE_LIBRARIES
C:/dev/gdcm/2.5/bin/vtkgdcm.dll
C:/dev/gdcm/2.5/bin/gdcmcommon.dll
C:/dev/gdcm/2.5/bin/gdcmcharls.dll
C:/dev/gdcm/2.5/bin/gdcmdict.dll
C:/dev/gdcm/2.5/bin/gdcmdsed.dll
C:/dev/gdcm/2.5/bin/gdcmexpat.dll
C:/dev/gdcm/2.5/bin/gdcmiod.dll
C:/dev/gdcm/2.5/bin/gdcmjpeg12.dll
C:/dev/gdcm/2.5/bin/gdcmjpeg16.dll
C:/dev/gdcm/2.5/bin/gdcmjpeg8.dll
C:/dev/gdcm/2.5/bin/gdcmmsff.dll
C:/dev/gdcm/2.5/bin/gdcmopenjpeg.dll
C:/dev/gdcm/2.5/bin/gdcmzlib.dll
C:/dev/gdcm/2.5/bin/gdcmmsff.dll
)
set(LIBXML2_PACKAGE_LIBRARIES
C:/dev/libxml2/2.9.1/bin/libiconv-2.dll
C:/dev/libxml2/2.9.1/bin/libxml2-2.dll
C:/dev/libxml2/2.9.1/bin/zlib1.dll
c:/dev/gdcm/2.6.3/bin/VTKCOMMONCORE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKIMAGINGCORE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKIMAGINGSOURCES-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKINTERACTIONSTYLE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKIOIMAGE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKRENDERINGCORE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKRENDERINGFREETYPE-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKRENDERINGOPENGL-6.3.DLL
c:/dev/gdcm/2.6.3/bin/VTKSYS-6.3.DLL
c:/dev/gdcm/2.6.3/bin/gdcmcharls.dll
c:/dev/gdcm/2.6.3/bin/gdcmCommon.dll
c:/dev/gdcm/2.6.3/bin/gdcmDICT.dll
c:/dev/gdcm/2.6.3/bin/gdcmDSED.dll
c:/dev/gdcm/2.6.3/bin/gdcmexpat.dll
c:/dev/gdcm/2.6.3/bin/gdcmgetopt.dll
c:/dev/gdcm/2.6.3/bin/gdcmIOD.dll
c:/dev/gdcm/2.6.3/bin/gdcmjpeg8.dll
c:/dev/gdcm/2.6.3/bin/gdcmjpeg12.dll
c:/dev/gdcm/2.6.3/bin/gdcmjpeg16.dll
c:/dev/gdcm/2.6.3/bin/gdcmMSFF.dll
c:/dev/gdcm/2.6.3/bin/gdcmopenjpeg.dll
c:/dev/gdcm/2.6.3/bin/gdcmjpeg16.dll
c:/dev/gdcm/2.6.3/bin/gdcmzlib.dll
c:/dev/gdcm/2.6.3/bin/vtkgdcm.dll
)
set(XERCES_C_PACKAGE_LIBRARIES
......@@ -393,8 +456,9 @@ if(WIN32 AND MSVC AND PACKAGING_NSIS)
endif() #! end compiler specific settings
#! Additional libraries to install with the installer
set(CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS
${QT_PACKAGE_LIRABRIES}
set(CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS
${QT_PACKAGE_LIBRARIES}
${QT_MANDATORY_WIN_RT_DLL}
${VTK_PACKAGE_LIBRARIES}
${ITK_PACKAGE_LIBRARIES}
${GDCM_PACKAGE_LIBRARIES}
......@@ -489,7 +553,7 @@ add_custom_target(camitk_package_source
#! This target create the installer / linux package.
#! On windows, you have configured with PACKAGING_NSIS=TRUE => all project names have their "-" replaced by "_" character
#! NSIS doesn't support "-" character.
add_custom_target(camitk_package
add_custom_target(camitk_NSIS_Windows_package
COMMAND ${CMAKE_COMMAND}
-E copy ${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h
${CMAKE_CURRENT_BINARY_DIR}/sdk/libraries/core/CamiTKVersion.h-backup
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment