comparison Plugins/Samples/StorageCommitmentScp/CMakeLists.txt @ 3664:85acfcc15829 storage-commitment

sample storage commitment plugin, C++ wrapper
author Sebastien Jodogne <s.jodogne@gmail.com>
date Wed, 12 Feb 2020 16:06:58 +0100
parents
children
comparison
equal deleted inserted replaced
3662:d8371b4302ff 3664:85acfcc15829
1 cmake_minimum_required(VERSION 2.8)
2
3 project(StorageCommitmentScp)
4
5 SET(PLUGIN_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(${SAMPLES_ROOT}/Common/OrthancPlugins.cmake)
14 include(${ORTHANC_ROOT}/Resources/CMake/JsonCppConfiguration.cmake)
15 include(${ORTHANC_ROOT}/Resources/CMake/BoostConfiguration.cmake)
16
17 add_library(StorageCommitmentScp SHARED
18 Plugin.cpp
19 ../Common/OrthancPluginCppWrapper.cpp
20 ${JSONCPP_SOURCES}
21 ${BOOST_SOURCES}
22 )
23
24 message("Setting the version of the plugin to ${PLUGIN_VERSION}")
25 add_definitions(
26 -DPLUGIN_VERSION="${PLUGIN_VERSION}"
27 )
28
29 set_target_properties(StorageCommitmentScp PROPERTIES
30 VERSION ${PLUGIN_VERSION}
31 SOVERSION ${PLUGIN_VERSION})
32
33 install(
34 TARGETS StorageCommitmentScp
35 RUNTIME DESTINATION lib # Destination for Windows
36 LIBRARY DESTINATION share/orthanc/plugins # Destination for Linux
37 )