summaryrefslogtreecommitdiff
path: root/cmake/plugin.cmake
diff options
context:
space:
mode:
authorVladislav Vaintroub <vvaintroub@mysql.com>2009-12-17 14:41:50 +0100
committerVladislav Vaintroub <vvaintroub@mysql.com>2009-12-17 14:41:50 +0100
commiteb3c44030bf398ddaf033be1a3b1b163faa9bce3 (patch)
treeb9698e003a32f65faf28d6032f377916cf93b648 /cmake/plugin.cmake
parent07bfd2617db894f9a6a4ad5998941d3517974bb7 (diff)
downloadmariadb-git-eb3c44030bf398ddaf033be1a3b1b163faa9bce3.tar.gz
Replace ADD_EXECUTABLE with MYSQL_ADD_EXECUTABLE for binaries that are installed.
MYSQL_ADD_EXECUTABLE will instructs CPack where to install the exe. On Windows, it also adds version resource and if -DSIGNCODE was given, will sign the exe in packaging step.
Diffstat (limited to 'cmake/plugin.cmake')
-rw-r--r--cmake/plugin.cmake19
1 files changed, 11 insertions, 8 deletions
diff --git a/cmake/plugin.cmake b/cmake/plugin.cmake
index 41fc3739979..b6a55b2ede0 100644
--- a/cmake/plugin.cmake
+++ b/cmake/plugin.cmake
@@ -120,7 +120,16 @@ MACRO(MYSQL_ADD_PLUGIN)
FORCE)
ENDIF()
ELSEIF(NOT WITHOUT_${plugin} AND NOT ARG_STATIC_ONLY AND NOT WITHOUT_DYNAMIC_PLUGINS)
-
+ IF(NOT ARG_MODULE_OUTPUT_NAME)
+ IF(ARG_STORAGE_ENGINE)
+ SET(ARG_MODULE_OUTPUT_NAME "ha_${target}")
+ ELSE()
+ SET(ARG_MODULE_OUTPUT_NAME "${target}")
+ ENDIF()
+ ENDIF()
+ IF(WIN32)
+ ADD_VERSION_INFO(${ARG_MODULE_OUTPUT_NAME} VFT_DLL SOURCES)
+ ENDIF()
ADD_LIBRARY(${target} MODULE ${SOURCES})
DTRACE_INSTRUMENT(${target})
SET_TARGET_PROPERTIES (${target} PROPERTIES PREFIX ""
@@ -142,13 +151,7 @@ MACRO(MYSQL_ADD_PLUGIN)
ENDIF()
ADD_DEPENDENCIES(${target} GenError ${ARG_DEPENDENCIES})
- IF(NOT ARG_MODULE_OUTPUT_NAME)
- IF(ARG_STORAGE_ENGINE)
- SET(ARG_MODULE_OUTPUT_NAME "ha_${target}")
- ELSE()
- SET(ARG_MODULE_OUTPUT_NAME "${target}")
- ENDIF()
- ENDIF()
+
SET_TARGET_PROPERTIES(${target} PROPERTIES
OUTPUT_NAME "${ARG_MODULE_OUTPUT_NAME}")
# Install dynamic library