Mercurial > hg > orthanc-databases
comparison MySQL/CMakeLists.txt @ 38:bc979149e138
dll versioning
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 16 Jul 2018 20:31:10 +0200 |
parents | 173176f8cef2 |
children | 4c3f767ead03 |
comparison
equal
deleted
inserted
replaced
37:23761c478d86 | 38:bc979149e138 |
---|---|
15 | 15 |
16 set(ENABLE_MYSQL_BACKEND ON) | 16 set(ENABLE_MYSQL_BACKEND ON) |
17 | 17 |
18 include(${CMAKE_SOURCE_DIR}/../Resources/CMake/DatabasesPluginConfiguration.cmake) | 18 include(${CMAKE_SOURCE_DIR}/../Resources/CMake/DatabasesPluginConfiguration.cmake) |
19 | 19 |
20 | |
21 if (${CMAKE_SYSTEM_NAME} STREQUAL "Windows") | |
22 execute_process( | |
23 COMMAND | |
24 ${PYTHON_EXECUTABLE} ${ORTHANC_ROOT}/Resources/WindowsResources.py | |
25 ${ORTHANC_PLUGIN_VERSION} "MySQL storage area plugin" OrthancMySQLStorage.dll | |
26 "MySQL as a database back-end to Orthanc (storage area)" | |
27 ERROR_VARIABLE Failure | |
28 OUTPUT_FILE ${AUTOGENERATED_DIR}/StorageVersion.rc | |
29 ) | |
30 | |
31 if (Failure) | |
32 message(FATAL_ERROR "Error while computing the version information: ${Failure}") | |
33 endif() | |
34 | |
35 execute_process( | |
36 COMMAND | |
37 ${PYTHON_EXECUTABLE} ${ORTHANC_ROOT}/Resources/WindowsResources.py | |
38 ${ORTHANC_PLUGIN_VERSION} "MySQL index plugin" OrthancMySQLIndex.dll | |
39 "MySQL as a database back-end to Orthanc (index)" | |
40 ERROR_VARIABLE Failure | |
41 OUTPUT_FILE ${AUTOGENERATED_DIR}/IndexVersion.rc | |
42 ) | |
43 | |
44 if (Failure) | |
45 message(FATAL_ERROR "Error while computing the version information: ${Failure}") | |
46 endif() | |
47 | |
48 set(INDEX_RESOURCES ${AUTOGENERATED_DIR}/IndexVersion.rc) | |
49 set(STORAGE_RESOURCES ${AUTOGENERATED_DIR}/StorageVersion.rc) | |
50 endif() | |
51 | |
52 | |
20 EmbedResources( | 53 EmbedResources( |
21 MYSQL_PREPARE_INDEX ${CMAKE_SOURCE_DIR}/Plugins/PrepareIndex.sql | 54 MYSQL_PREPARE_INDEX ${CMAKE_SOURCE_DIR}/Plugins/PrepareIndex.sql |
22 ) | 55 ) |
23 | 56 |
24 add_library(OrthancMySQLIndex SHARED | 57 add_library(OrthancMySQLIndex SHARED |
58 ${INDEX_RESOURCES} | |
25 ${ORTHANC_DATABASES_ROOT}/Framework/Plugins/PluginInitialization.cpp | 59 ${ORTHANC_DATABASES_ROOT}/Framework/Plugins/PluginInitialization.cpp |
26 Plugins/IndexPlugin.cpp | 60 Plugins/IndexPlugin.cpp |
27 Plugins/MySQLIndex.cpp | 61 Plugins/MySQLIndex.cpp |
28 | 62 |
29 ${DATABASES_SOURCES} | 63 ${DATABASES_SOURCES} |
30 ${AUTOGENERATED_SOURCES} | 64 ${AUTOGENERATED_SOURCES} |
31 ) | 65 ) |
32 | 66 |
33 add_library(OrthancMySQLStorage SHARED | 67 add_library(OrthancMySQLStorage SHARED |
34 ${ORTHANC_DATABASES_ROOT}/Framework/Plugins/PluginInitialization.cpp | 68 ${ORTHANC_DATABASES_ROOT}/Framework/Plugins/PluginInitialization.cpp |
69 ${STORAGE_RESOURCES} | |
35 Plugins/MySQLStorageArea.cpp | 70 Plugins/MySQLStorageArea.cpp |
36 Plugins/StoragePlugin.cpp | 71 Plugins/StoragePlugin.cpp |
37 | 72 |
38 ${DATABASES_SOURCES} | 73 ${DATABASES_SOURCES} |
39 ${AUTOGENERATED_SOURCES} | 74 ${AUTOGENERATED_SOURCES} |