Fix several path issues.

This commit is contained in:
Honza Horak 2014-08-05 07:29:17 +02:00
parent 088c1e447f
commit 7de9cfe709
6 changed files with 24 additions and 12 deletions

View File

@ -7,7 +7,7 @@ provided in this distribution.
Thus, it is recommended to use these configuration files as an addition to the
default my.cnf configuration file.
Since default my.cnf contains `!includedir @sysconfdir@/my.cnf.d` directive, it is
recommended to copy required configuration under @sysconfdir@/my.cnf.d/ directory,
Since default my.cnf contains `!includedir @INSTALL_SYSCONF2DIR@` directive, it is
recommended to copy required configuration under @INSTALL_SYSCONF2DIR@ directory,
so the default my.cnf specifications will be extended.

View File

@ -151,3 +151,15 @@ diff -up mariadb-10.0.12/scripts/mytop.sh.cmakepaths mariadb-10.0.12/scripts/myt
for (@search_dirs)
{
diff -up mariadb-10.0.12/scripts/CMakeLists.txt.patchs mariadb-10.0.12/scripts/CMakeLists.txt
--- mariadb-10.0.12/scripts/CMakeLists.txt.patchs 2014-08-04 22:21:02.577917599 +0200
+++ mariadb-10.0.12/scripts/CMakeLists.txt 2014-08-04 22:21:42.712940832 +0200
@@ -221,7 +221,7 @@ INSTALL_SCRIPT(
ENDIF()
SET(prefix "${CMAKE_INSTALL_PREFIX}")
-SET(sysconfdir ${prefix})
+SET(sysconfdir ${prefix}/${INSTALL_SYSCONFDIR})
SET(bindir ${prefix}/${INSTALL_BINDIR})
SET(libexecdir ${prefix}/${INSTALL_SBINDIR})
SET(scriptdir ${prefix}/${INSTALL_BINDIR})

View File

@ -529,7 +529,7 @@ cmake . -DBUILD_CONFIG=mysql_release \
-DLOG_LOCATION="%{logfile}" \
-DLOG_LOCATION_COMPAT="%{old_logfile}" \
-DPID_FILE_DIR="%{_localstatedir}/run/%{daemon_name}" \
-DPID_FILE_DIR_COMAPT="%{_localstatedir}/run/%{mysqld_unit}" \
-DPID_FILE_DIR_COMPAT="%{_localstatedir}/run/%{mysqld_unit}" \
-DNICE_PROJECT_NAME="MariaDB" \
-DRPM="%{?rhel:rhel%{rhel}}%{!?rhel:fedora%{fedora}}" \
-DCMAKE_INSTALL_PREFIX="%{_prefix}" \
@ -626,7 +626,7 @@ mkdir -p %{buildroot}%{_localstatedir}/run/%{name}
install -p -m 0755 -d %{buildroot}%{_localstatedir}/lib/mysql
%if %{ship_my_cnf}
install -D -p -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/my.cnf
install -D -p -m 0644 scripts/my.cnf %{buildroot}%{_sysconfdir}/my.cnf
%else
rm -f %{buildroot}%{_sysconfdir}/my.cnf.d/mysql-clients.cnf
rm -f %{buildroot}%{_sysconfdir}/my.cnf

View File

@ -14,16 +14,16 @@ symbolic-links=0
# Otherwise the RPMs would be in conflict.
# Settings for particular implementations like MariaDB are then
# defined in appropriate sections; for MariaDB server in [mariadb] section in
# @sysconfdir@/my.cnf.d/server.cnf (part of mariadb-server).
# @INSTALL_SYSCONF2DIR@/server.cnf (part of mariadb-server).
# It doesn't matter that we set these settings only for [mysqld] here,
# because they will be read and used in mysqld_safe as well.
log-error=@LOG_LOCATION_COMPAT@
pid-file=@PID_FILE_DIR_COMAPT@/@DAEMON_NAME_COMPAT@.pid
pid-file=@PID_FILE_DIR_COMPAT@/@DAEMON_NAME_COMPAT@.pid
[mysqld_safe]
#
# include all files from the config directory
#
!includedir @sysconfdir@/my.cnf.d
!includedir @INSTALL_SYSCONF2DIR@

View File

@ -47,12 +47,12 @@ datadir="$result"
# returns log-error
# log-error might be defined in mysqld_safe and mysqld sections,
# the former has bigger priority
get_mysql_option "$server_sections" log-error "`hostname`.err"
errlogfile="$datadir/$result"
get_mysql_option "$server_sections" log-error "$datadir/`hostname`.err"
errlogfile="$result"
get_mysql_option "$server_sections" socket "@MYSQL_UNIX_ADDR@"
socketfile="$result"
get_mysql_option "$server_sections" pid-file "`hostname`.pid"
pidfile="$datadir/$result"
get_mysql_option "$server_sections" pid-file "$datadir/`hostname`.pid"
pidfile="$result"

View File

@ -1,2 +1,2 @@
d @PID_FILE_DIR@ 0755 mysql mysql -
d @PID_FILE_DIR_COMAPT@ 0755 mysql mysql -
d @PID_FILE_DIR_COMPAT@ 0755 mysql mysql -