diff options
author | Sergei Golubchik <sergii@pisem.net> | 2013-04-15 15:09:22 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2013-04-15 15:09:22 +0200 |
commit | a9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254 (patch) | |
tree | a9df7341e91623f62fe37cd47fce139d8888fc95 /cmake | |
parent | 3a1c91d87d69ef243b3e78be6089102cafef0a8e (diff) | |
parent | f57ecb7786177e0af3b1e3ec94302720b2e0f967 (diff) | |
download | mariadb-git-a9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254.tar.gz |
10.0-base merge
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/cpack_rpm.cmake | 34 | ||||
-rw-r--r-- | cmake/install_layout.cmake | 10 | ||||
-rw-r--r-- | cmake/maintainer.cmake | 4 | ||||
-rw-r--r-- | cmake/os/WindowsCache.cmake | 1 | ||||
-rw-r--r-- | cmake/plugin.cmake | 8 |
5 files changed, 34 insertions, 23 deletions
diff --git a/cmake/cpack_rpm.cmake b/cmake/cpack_rpm.cmake index 056366e6ee6..ee7c4af7155 100644 --- a/cmake/cpack_rpm.cmake +++ b/cmake/cpack_rpm.cmake @@ -2,7 +2,7 @@ IF(RPM) SET(CPACK_GENERATOR "RPM") SET(CPACK_RPM_PACKAGE_DEBUG 1) -SET(INSTALL_LAYOUT "RPM") +SET(CPACK_PACKAGING_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}) CMAKE_MINIMUM_REQUIRED(VERSION 2.8.7) SET(CPACK_RPM_COMPONENT_INSTALL ON) @@ -49,9 +49,13 @@ MariaDB bug reports should be submitted through https://mariadb.atlassian.net/ SET(CPACK_RPM_SPEC_MORE_DEFINE " %define mysql_vendor ${CPACK_PACKAGE_VENDOR} %define mysqlversion ${MYSQL_NO_DASH_VERSION} -%define mysqldatadir /var/lib/mysql +%define mysqlbasedir ${CMAKE_INSTALL_PREFIX} +%define mysqldatadir ${INSTALL_MYSQLDATADIR} %define mysqld_user mysql %define mysqld_group mysql +%define _bindir ${CMAKE_INSTALL_PREFIX}/${INSTALL_BINDIR} +%define _sbindir ${CMAKE_INSTALL_PREFIX}/${INSTALL_SBINDIR} +%define _sysconfdir ${INSTALL_SYSCONFDIR} ") # this creative hack is described here: http://www.cmake.org/pipermail/cmake/2012-January/048416.html @@ -68,18 +72,18 @@ SET(ignored "%ignore /etc" "%ignore /etc/init.d" "%ignore /etc/logrotate.d" - "%ignore /usr" - "%ignore /usr/bin" - "%ignore /usr/include" - "%ignore /usr/lib" - "%ignore /usr/lib64" - "%ignore /usr/sbin" - "%ignore /usr/share" - "%ignore /usr/share/aclocal" - "%ignore /usr/share/doc" - "%ignore /usr/share/man" - "%ignore /usr/share/man/man1*" - "%ignore /usr/share/man/man8*" + "%ignore ${CMAKE_INSTALL_PREFIX}" + "%ignore ${CMAKE_INSTALL_PREFIX}/bin" + "%ignore ${CMAKE_INSTALL_PREFIX}/include" + "%ignore ${CMAKE_INSTALL_PREFIX}/lib" + "%ignore ${CMAKE_INSTALL_PREFIX}/lib64" + "%ignore ${CMAKE_INSTALL_PREFIX}/sbin" + "%ignore ${CMAKE_INSTALL_PREFIX}/share" + "%ignore ${CMAKE_INSTALL_PREFIX}/share/aclocal" + "%ignore ${CMAKE_INSTALL_PREFIX}/share/doc" + "%ignore ${CMAKE_INSTALL_PREFIX}/share/man" + "%ignore ${CMAKE_INSTALL_PREFIX}/share/man/man1*" + "%ignore ${CMAKE_INSTALL_PREFIX}/share/man/man8*" ) SET(CPACK_RPM_server_USER_FILELIST ${ignored} "%config(noreplace) /etc/my.cnf.d/*") @@ -103,7 +107,7 @@ SET(CPACK_RPM_devel_PACKAGE_OBSOLETES "mysql-devel MySQL-devel MySQL-OurDelta-de SET(CPACK_RPM_devel_PACKAGE_PROVIDES "MariaDB-devel MySQL-devel mysql-devel") SET(CPACK_RPM_server_PACKAGE_OBSOLETES "MariaDB mysql mysql-server MySQL-server MySQL-OurDelta-server") -SET(CPACK_RPM_server_PACKAGE_PROVIDES "MariaDB MariaDB-server MySQL-server config(MariaDB-server) msqlormysql mysql mysql-server") +SET(CPACK_RPM_server_PACKAGE_PROVIDES "MariaDB MariaDB-server MySQL-server config(MariaDB-server) msqlormysql mysql mysql(x86-32) mysql(x86-64) mysql-server") SET(CPACK_RPM_server_PRE_INSTALL_SCRIPT_FILE ${CMAKE_SOURCE_DIR}/support-files/rpm/server-prein.sh) SET(CPACK_RPM_server_PRE_UNINSTALL_SCRIPT_FILE ${CMAKE_SOURCE_DIR}/support-files/rpm/server-preun.sh) SET(CPACK_RPM_server_POST_INSTALL_SCRIPT_FILE ${CMAKE_SOURCE_DIR}/support-files/rpm/server-postin.sh) diff --git a/cmake/install_layout.cmake b/cmake/install_layout.cmake index 0542b8d2e21..22b0255a22a 100644 --- a/cmake/install_layout.cmake +++ b/cmake/install_layout.cmake @@ -67,7 +67,13 @@ # http://forge.mysql.com/wiki/CMake#Fine-tuning_installation_paths IF(NOT INSTALL_LAYOUT) - SET(INSTALL_LAYOUT "STANDALONE") + IF(DEB) + SET(INSTALL_LAYOUT "DEB") + ELSEIF(RPM) + SET(INSTALL_LAYOUT "RPM") + ELSE() + SET(INSTALL_LAYOUT "STANDALONE") + ENDIF() ENDIF() SET(INSTALL_LAYOUT "${INSTALL_LAYOUT}" @@ -187,7 +193,7 @@ SET(INSTALL_SHAREDIR_DEB "share") SET(INSTALL_MYSQLSHAREDIR_DEB "share/mysql") SET(INSTALL_MYSQLTESTDIR_DEB "mysql-test") SET(INSTALL_SQLBENCHDIR_DEB ".") -SET(INSTALL_SUPPORTFILESDIR_DEB "support-files") +SET(INSTALL_SUPPORTFILESDIR_DEB "share/mysql") # SET(INSTALL_MYSQLDATADIR_DEB "/var/lib/mysql") SET(INSTALL_PLUGINTESTDIR_DEB ${plugin_tests}) diff --git a/cmake/maintainer.cmake b/cmake/maintainer.cmake index d52405e8bcc..874e05b8a43 100644 --- a/cmake/maintainer.cmake +++ b/cmake/maintainer.cmake @@ -18,7 +18,7 @@ INCLUDE(CheckCCompilerFlag) # Setup GCC (GNU C compiler) warning options. MACRO(SET_MYSQL_MAINTAINER_GNU_C_OPTIONS) SET(MY_MAINTAINER_WARNINGS - "-Wall -Wextra -Wunused -Wwrite-strings -Wno-strict-aliasing -Wno-invalid-offsetof -DFORCE_INIT_OF_VARS") + "-Wall -Wextra -Wunused -Wwrite-strings -Wno-strict-aliasing -DFORCE_INIT_OF_VARS") CHECK_C_COMPILER_FLAG("-Wno-missing-field-initializers" HAVE_NO_MISSING_FIELD_INITIALIZERS) @@ -44,7 +44,7 @@ ENDMACRO() # Setup G++ (GNU C++ compiler) warning options. MACRO(SET_MYSQL_MAINTAINER_GNU_CXX_OPTIONS) SET(MY_MAINTAINER_CXX_WARNINGS - "${MY_MAINTAINER_WARNINGS} -Wno-unused-parameter -Woverloaded-virtual" + "${MY_MAINTAINER_WARNINGS} -Wno-invalid-offsetof -Wno-unused-parameter -Woverloaded-virtual" CACHE INTERNAL "C++ warning options used in maintainer builds.") ENDMACRO() diff --git a/cmake/os/WindowsCache.cmake b/cmake/os/WindowsCache.cmake index b93a1c12a2e..83ea3b0f3b3 100644 --- a/cmake/os/WindowsCache.cmake +++ b/cmake/os/WindowsCache.cmake @@ -267,6 +267,7 @@ SET(HAVE_SYNCH_H CACHE INTERNAL "") SET(HAVE_SYSENT_H CACHE INTERNAL "") SET(HAVE_SYS_CDEFS_H CACHE INTERNAL "") SET(HAVE_SYS_DIR_H CACHE INTERNAL "") +SET(HAVE_SYS_EVENT_H CACHE INTERNAL "") SET(HAVE_SYS_ERRLIST CACHE INTERNAL "") SET(HAVE_SYS_FILE_H CACHE INTERNAL "") SET(HAVE_SYS_FPU_H CACHE INTERNAL "") diff --git a/cmake/plugin.cmake b/cmake/plugin.cmake index 2978fb1a13c..f016d8eab4f 100644 --- a/cmake/plugin.cmake +++ b/cmake/plugin.cmake @@ -171,12 +171,12 @@ MACRO(MYSQL_ADD_PLUGIN) IF(ARG_MANDATORY) SET (mysql_mandatory_plugins - "${mysql_mandatory_plugins} builtin_maria_${target}_plugin," - PARENT_SCOPE) + "${mysql_mandatory_plugins} builtin_maria_${target}_plugin,") + SET (mysql_mandatory_plugins ${mysql_mandatory_plugins} PARENT_SCOPE) ELSE() SET (mysql_optional_plugins - "${mysql_optional_plugins} builtin_maria_${target}_plugin," - PARENT_SCOPE) + "${mysql_optional_plugins} builtin_maria_${target}_plugin,") + SET (mysql_optional_plugins ${mysql_optional_plugins} PARENT_SCOPE) ENDIF() ELSEIF(NOT WITHOUT_${plugin} AND NOT ARG_STATIC_ONLY AND NOT WITHOUT_DYNAMIC_PLUGINS) |