From 2b39e065d70078daa097a811c939003a071dcb70 Mon Sep 17 00:00:00 2001 From: Jonathan Perkin Date: Fri, 17 Dec 2010 23:03:23 +0000 Subject: [PATCH 1/3] bug#51264: MySQL.prefPane fails to run @prefix@ was erroneously set to '.' with the STANDALONE install layout, when it should instead be set to CMAKE_INSTALL_PREFIX, this was likely accidentally copied from scripts/CMakeLists.txt which has similar handling specifically for mysql_install_db.sh mysql.server init script can now find the install, assuming the defaults have been chosen. --- support-files/CMakeLists.txt | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/support-files/CMakeLists.txt b/support-files/CMakeLists.txt index 2d1d1e83b8b..f8a65e75d4d 100644 --- a/support-files/CMakeLists.txt +++ b/support-files/CMakeLists.txt @@ -48,14 +48,7 @@ FOREACH(inifile my-huge my-innodb-heavy-4G my-large my-medium my-small) ENDFOREACH() IF(UNIX) - # XXX: again, used elsewhere (scripts/), should be standardised in - # XXX: install_layout.cmake - IF(INSTALL_LAYOUT MATCHES "STANDALONE") - SET(prefix ".") - ELSE() - SET(prefix ${CMAKE_INSTALL_PREFIX}) - ENDIF() - + SET(prefix ${CMAKE_INSTALL_PREFIX}) FOREACH(script mysqld_multi.server mysql-log-rotate binary-configure config.medium.ini config.small.ini config.huge.ini ndb-config-2-node.ini) CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/${script}.sh From a3deb16810cef3181350e77c87f33fc044ced0b1 Mon Sep 17 00:00:00 2001 From: Jonathan Perkin Date: Fri, 17 Dec 2010 23:08:43 +0000 Subject: [PATCH 2/3] bug#51925: 5.5 installed header file layout is incorrect The 'mysql' include sub-directory was copied directly into include/ rather than retaining its own directory. Fix this, and update mysql_config which needs additional logic to detect the correct prefix for includes. --- include/CMakeLists.txt | 4 +--- scripts/mysql_config.sh | 6 +++++- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/include/CMakeLists.txt b/include/CMakeLists.txt index 5334fc0f5ae..e89929d159d 100644 --- a/include/CMakeLists.txt +++ b/include/CMakeLists.txt @@ -59,6 +59,4 @@ SET(HEADERS ) INSTALL(FILES ${HEADERS} DESTINATION ${INSTALL_INCLUDEDIR} COMPONENT Development) -INSTALL(DIRECTORY mysql/ DESTINATION ${INSTALL_INCLUDEDIR} COMPONENT Development FILES_MATCHING PATTERN "*.h" ) - - +INSTALL(DIRECTORY mysql/ DESTINATION ${INSTALL_INCLUDEDIR}/mysql COMPONENT Development FILES_MATCHING PATTERN "*.h") diff --git a/scripts/mysql_config.sh b/scripts/mysql_config.sh index 69ec88d6724..97a8a723043 100644 --- a/scripts/mysql_config.sh +++ b/scripts/mysql_config.sh @@ -92,7 +92,11 @@ plugindir_rel=`echo $plugindir | sed -e "s;^$basedir/;;"` fix_path plugindir $plugindir_rel lib/mysql/plugin lib/plugin pkgincludedir='@pkgincludedir@' -fix_path pkgincludedir include/mysql include +if [ -f $basedir/include/mysql/mysql.h ]; then + pkgincludedir="$basedir/include/mysql" +elif [ -f $basedir/include/mysql.h ]; then + pkgincludedir="$basedir/include" +fi version='@VERSION@' socket='@MYSQL_UNIX_ADDR@' From 6c70c33f12534917c68e691f20be574007cff589 Mon Sep 17 00:00:00 2001 From: Jonathan Perkin Date: Fri, 17 Dec 2010 23:13:33 +0000 Subject: [PATCH 3/3] bug#51925: 5.5 installed header file layout is incorrect Additional space-in-directory-name protection. --- scripts/mysql_config.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/mysql_config.sh b/scripts/mysql_config.sh index 97a8a723043..67484ec13b7 100644 --- a/scripts/mysql_config.sh +++ b/scripts/mysql_config.sh @@ -92,9 +92,9 @@ plugindir_rel=`echo $plugindir | sed -e "s;^$basedir/;;"` fix_path plugindir $plugindir_rel lib/mysql/plugin lib/plugin pkgincludedir='@pkgincludedir@' -if [ -f $basedir/include/mysql/mysql.h ]; then +if [ -f "$basedir/include/mysql/mysql.h" ]; then pkgincludedir="$basedir/include/mysql" -elif [ -f $basedir/include/mysql.h ]; then +elif [ -f "$basedir/include/mysql.h" ]; then pkgincludedir="$basedir/include" fi