diff options
author | Vladislav Vaintroub <vvaintroub@u8> | 2010-01-15 01:21:43 +0100 |
---|---|---|
committer | Vladislav Vaintroub <vvaintroub@u8> | 2010-01-15 01:21:43 +0100 |
commit | 4e04b863552da3ffc885a71aa4a093b575a40d8a (patch) | |
tree | 4be2b747e2811a203c78030057c35d2ed107aa0d /scripts | |
parent | 166c321141261b8f239009cd361bfc251f1b9273 (diff) | |
download | mariadb-git-4e04b863552da3ffc885a71aa4a093b575a40d8a.tar.gz |
port some mysql_binary_distribution hacks to cmake
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/CMakeLists.txt | 27 |
1 files changed, 24 insertions, 3 deletions
diff --git a/scripts/CMakeLists.txt b/scripts/CMakeLists.txt index 1acbe944599..98fa00d01ea 100755 --- a/scripts/CMakeLists.txt +++ b/scripts/CMakeLists.txt @@ -133,8 +133,30 @@ ENDIF(UNIX) -set(prefix "${CMAKE_INSTALL_PREFIX}") +# Really ugly, one script, "mysql_install_db", needs prefix set to ".", +# i.e. makes access relative the current directory. This matches +# the documentation, so better not change this. + +SET(prefix .) +SET(bindir ./bin) +SET(sbindir ./bin) +SET(scriptdir ./bin) +SET(libexecdir ./bin) +SET(pkgdatadir ./share) +SET(localstatedir ./data) +CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/mysql_install_db.sh + ${CMAKE_CURRENT_BINARY_DIR}/mysql_install_db ESCAPE_QUOTES @ONLY) + +INSTALL(FILES + "${CMAKE_CURRENT_BINARY_DIR}/mysql_install_db" + DESTINATION bin + PERMISSIONS OWNER_READ OWNER_WRITE + OWNER_EXECUTE GROUP_READ GROUP_EXECUTE + WORLD_READ WORLD_EXECUTE + ) + +SET(prefix "${CMAKE_INSTALL_PREFIX}") SET(sysconfdir ${prefix}) SET(bindir ${prefix}/bin) SET(libexecdir ${prefix}/bin) @@ -253,7 +275,6 @@ ELSE() mysqld_multi mysqlaccess mysqlaccess.conf - mysql_install_db ) FOREACH(file ${BIN_SCRIPTS}) IF(EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/${file}.sh) @@ -288,7 +309,7 @@ ELSE() # For some reason, mysqld_safe needs to be also in scripts directory INSTALL(FILES - "${CMAKE_CURRENT_BINARY_DIR}/mysql_install_db" + "${CMAKE_CURRENT_BINARY_DIR}/mysqld_safe" DESTINATION scripts PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE |