-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathCMakeLists.txt
33 lines (28 loc) · 1.25 KB
/
CMakeLists.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DHAVE_HANDLERSOCKET")
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DHAVE_HANDLERSOCKET")
IF(HAVE_WVLA)
SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} -Wno-vla")
SET(CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -Wno-vla")
ENDIF()
SET(VP_SOURCES
vp_param.cc vp_table.cc vp_udf.cc vp_copy_tables.cc ha_vp.cc vp_udf.def)
IF(EXISTS ${PROJECT_SOURCE_DIR}/storage/mysql_storage_engine.cmake)
SET(CMAKE_CXX_FLAGS_DEBUG
"${CMAKE_CXX_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR /Zi")
SET(CMAKE_C_FLAGS_DEBUG
"${CMAKE_C_FLAGS_DEBUG} -DSAFEMALLOC -DSAFE_MUTEX -DUSE_SYMDIR /Zi")
SET(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /MAP /MAPINFO:EXPORTS")
INCLUDE("${PROJECT_SOURCE_DIR}/storage/mysql_storage_engine.cmake")
INCLUDE_DIRECTORIES(
${CMAKE_SOURCE_DIR}/include
${CMAKE_SOURCE_DIR}/sql
${CMAKE_SOURCE_DIR}/regex)
MYSQL_STORAGE_ENGINE(VP)
ELSE()
INSTALL(FILES
${CMAKE_SOURCE_DIR}/storage/vp/scripts/install_vp.sql
DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server
)
SET(VP_DEB_FILES "usr/lib/mysql/plugin/ha_vp.so usr/share/mysql/install_vp.sql" PARENT_SCOPE)
MYSQL_ADD_PLUGIN(vp ${VP_SOURCES} STORAGE_ENGINE MODULE_ONLY MODULE_OUTPUT_NAME "ha_vp")
ENDIF()