comparison Plugins/Samples/ModalityWorklists/CMakeLists.txt @ 1802:138664eb59de worklists

sample worklist plugin
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 20 Nov 2015 15:54:07 +0100
parents
children 9c2ffc4e938b
comparison
equal deleted inserted replaced
1801:2c60c357ee3e 1802:138664eb59de
1 cmake_minimum_required(VERSION 2.8)
2
3 project(SampleModalityWorklists)
4
5 SET(SAMPLE_MODALITY_WORKLISTS_VERSION "0.0" CACHE STRING "Version of the plugin")
6 SET(STATIC_BUILD OFF CACHE BOOL "Static build of the third-party libraries (necessary for Windows)")
7 SET(ALLOW_DOWNLOADS OFF CACHE BOOL "Allow CMake to download packages")
8
9 SET(USE_SYSTEM_JSONCPP ON CACHE BOOL "Use the system version of JsonCpp")
10 SET(USE_SYSTEM_BOOST ON CACHE BOOL "Use the system version of boost")
11
12 set(SAMPLES_ROOT ${CMAKE_SOURCE_DIR}/..)
13 include(${CMAKE_SOURCE_DIR}/../Common/OrthancPlugins.cmake)
14 include(${ORTHANC_ROOT}/Resources/CMake/JsonCppConfiguration.cmake)
15 include(${ORTHANC_ROOT}/Resources/CMake/BoostConfiguration.cmake)
16
17 add_library(SampleModalityWorklists SHARED
18 Plugin.cpp
19 ${JSONCPP_SOURCES}
20 ${BOOST_SOURCES}
21 )
22
23 message("Setting the version of the plugin to ${SAMPLE_MODALITY_WORKLISTS_VERSION}")
24 add_definitions(
25 -DSAMPLE_MODALITY_WORKLISTS_VERSION="${SAMPLE_MODALITY_WORKLISTS_VERSION}"
26 -DDEFAULT_WORKLISTS_FOLDER="${CMAKE_SOURCE_DIR}/WorklistsDatabase"
27 )
28
29 set_target_properties(SampleModalityWorklists PROPERTIES
30 VERSION ${SAMPLE_MODALITY_WORKLISTS_VERSION}
31 SOVERSION ${SAMPLE_MODALITY_WORKLISTS_VERSION})
32
33 install(
34 TARGETS SampleModalityWorklists
35 RUNTIME DESTINATION lib # Destination for Windows
36 LIBRARY DESTINATION share/orthanc/plugins # Destination for Linux
37 )