mirror of
https://github.com/MariaDB/server.git
synced 2025-01-28 17:54:16 +01:00
MDEV-11790 WITHOUT_SERVER installs mysqld_safe_helper
Don't install server files if WITHOUT_SERVER is specified. "Server files" are defined as files going into the MariaDB-Server RPM, that is files in the components Server, ManPagesServer, Server_Scripts, IniFiles, SuportFiles, and Readme.
This commit is contained in:
parent
bd5cf02bbe
commit
33eccb5776
6 changed files with 28 additions and 5 deletions
|
@ -165,6 +165,12 @@ ENDIF()
|
|||
OPTION (WITH_UNIT_TESTS "Compile MySQL with unit tests" ON)
|
||||
MARK_AS_ADVANCED(CYBOZU BACKUP_TEST WITHOUT_SERVER DISABLE_SHARED)
|
||||
|
||||
IF (WITHOUT_SERVER)
|
||||
SET (SKIP_COMPONENTS "Server|IniFiles|SuportFiles|Readme")
|
||||
ELSE()
|
||||
SET (SKIP_COMPONENTS "N-O-N-E")
|
||||
ENDIF()
|
||||
|
||||
OPTION(NOT_FOR_DISTRIBUTION "Allow linking with GPLv2-incompatible system libraries. Only set it you never plan to distribute the resulting binaries" OFF)
|
||||
|
||||
include(CheckCSourceCompiles)
|
||||
|
|
|
@ -115,6 +115,10 @@ FUNCTION(INSTALL_SCRIPT)
|
|||
SET(COMP)
|
||||
ENDIF()
|
||||
|
||||
IF (COMP MATCHES ${SKIP_COMPONENTS})
|
||||
RETURN()
|
||||
ENDIF()
|
||||
|
||||
INSTALL(FILES
|
||||
${script}
|
||||
DESTINATION ${ARG_DESTINATION}
|
||||
|
@ -138,6 +142,10 @@ FUNCTION(INSTALL_DOCUMENTATION)
|
|||
SET(destination ${INSTALL_DOCDIR})
|
||||
ENDIF()
|
||||
|
||||
IF (ARG_COMPONENT MATCHES ${SKIP_COMPONENTS})
|
||||
RETURN()
|
||||
ENDIF()
|
||||
|
||||
STRING(TOUPPER ${ARG_COMPONENT} COMPUP)
|
||||
IF(CPACK_COMPONENT_${COMPUP}_GROUP)
|
||||
SET(group ${CPACK_COMPONENT_${COMPUP}_GROUP})
|
||||
|
|
|
@ -59,6 +59,9 @@ FUNCTION (MYSQL_ADD_EXECUTABLE)
|
|||
ELSE()
|
||||
SET(COMP COMPONENT Client)
|
||||
ENDIF()
|
||||
IF (COMP MATCHES ${SKIP_COMPONENTS})
|
||||
RETURN()
|
||||
ENDIF()
|
||||
MYSQL_INSTALL_TARGETS(${target} DESTINATION ${ARG_DESTINATION} ${COMP})
|
||||
ENDIF()
|
||||
ENDFUNCTION()
|
||||
|
|
|
@ -74,6 +74,7 @@ IF(UNIX)
|
|||
)
|
||||
ENDIF()
|
||||
|
||||
IF (NOT WITHOUT_SERVER)
|
||||
INSTALL(FILES
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/mysql_system_tables.sql
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/mysql_system_tables_data.sql
|
||||
|
@ -83,6 +84,7 @@ INSTALL(FILES
|
|||
${FIX_PRIVILEGES_SQL}
|
||||
DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server
|
||||
)
|
||||
ENDIF()
|
||||
|
||||
# TCMalloc hacks
|
||||
IF(MALLOC_LIB)
|
||||
|
|
|
@ -44,12 +44,14 @@ SET(files
|
|||
errmsg-utf8.txt
|
||||
)
|
||||
|
||||
FOREACH (dir ${dirs})
|
||||
INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${dir}
|
||||
DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server)
|
||||
ENDFOREACH()
|
||||
INSTALL(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/charsets DESTINATION ${INSTALL_MYSQLSHAREDIR}
|
||||
COMPONENT Common PATTERN "languages.html" EXCLUDE
|
||||
)
|
||||
|
||||
INSTALL(FILES ${files} DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server)
|
||||
IF (NOT WITHOUT_SERVER)
|
||||
FOREACH (dir ${dirs})
|
||||
INSTALL(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/${dir}
|
||||
DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server)
|
||||
ENDFOREACH()
|
||||
INSTALL(FILES ${files} DESTINATION ${INSTALL_MYSQLSHAREDIR} COMPONENT Server)
|
||||
ENDIF()
|
||||
|
|
|
@ -41,12 +41,14 @@ ELSE()
|
|||
SET(inst_location ${INSTALL_SUPPORTFILESDIR})
|
||||
ENDIF()
|
||||
|
||||
IF (NOT WITHOUT_SERVER)
|
||||
FOREACH(inifile my-huge my-innodb-heavy-4G my-large my-medium my-small)
|
||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/${inifile}.cnf.sh
|
||||
${CMAKE_CURRENT_BINARY_DIR}/${inifile}.${ini_file_extension} @ONLY)
|
||||
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/${inifile}.${ini_file_extension}
|
||||
DESTINATION ${inst_location} COMPONENT IniFiles)
|
||||
ENDFOREACH()
|
||||
ENDIF()
|
||||
|
||||
IF(UNIX)
|
||||
SET(prefix ${CMAKE_INSTALL_PREFIX})
|
||||
|
|
Loading…
Add table
Reference in a new issue