diff options
author | 2014-05-16 01:49:43 +0000 | |
---|---|---|
committer | 2014-05-16 01:49:43 +0000 | |
commit | 19a4b392019a8f55d53c784e8b039152fc0d1a38 (patch) | |
tree | ddffe6b9362edb7772c67f03e0b5083f7df56699 /dev-db | |
parent | Version bump. (diff) | |
download | gentoo-2-19a4b392019a8f55d53c784e8b039152fc0d1a38.tar.gz gentoo-2-19a4b392019a8f55d53c784e8b039152fc0d1a38.tar.bz2 gentoo-2-19a4b392019a8f55d53c784e8b039152fc0d1a38.zip |
Revbump to fix bug 491348, remove old
(Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key 67C78E1D)
Diffstat (limited to 'dev-db')
-rw-r--r-- | dev-db/mysql-init-scripts/ChangeLog | 10 | ||||
-rw-r--r-- | dev-db/mysql-init-scripts/files/mysql-5.1.67-init.d-r1 (renamed from dev-db/mysql-init-scripts/files/mysql-5.1.53-init.d) | 38 | ||||
-rw-r--r-- | dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r3.ebuild | 56 | ||||
-rw-r--r-- | dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r7.ebuild (renamed from dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r2.ebuild) | 24 |
4 files changed, 48 insertions, 80 deletions
diff --git a/dev-db/mysql-init-scripts/ChangeLog b/dev-db/mysql-init-scripts/ChangeLog index 8b4d274a8891..df01f197e59b 100644 --- a/dev-db/mysql-init-scripts/ChangeLog +++ b/dev-db/mysql-init-scripts/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for dev-db/mysql-init-scripts # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog,v 1.38 2014/01/11 09:33:00 pacho Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog,v 1.39 2014/05/16 01:49:43 grknight Exp $ + +*mysql-init-scripts-2.0_pre1-r7 (16 May 2014) + + 16 May 2014; Brian Evans <grknight@gentoo.org> +files/mysql-5.1.67-init.d-r1, + +mysql-init-scripts-2.0_pre1-r7.ebuild, -files/mysql-5.1.53-init.d, + -mysql-init-scripts-2.0_pre1-r2.ebuild, + -mysql-init-scripts-2.0_pre1-r3.ebuild: + Revbump to fix bug 491348, remove old 11 Jan 2014; Pacho Ramos <pacho@gentoo.org> mysql-init-scripts-2.0_pre1-r6.ebuild: diff --git a/dev-db/mysql-init-scripts/files/mysql-5.1.53-init.d b/dev-db/mysql-init-scripts/files/mysql-5.1.67-init.d-r1 index d824b6ae650e..5ff7c32aa108 100644 --- a/dev-db/mysql-init-scripts/files/mysql-5.1.53-init.d +++ b/dev-db/mysql-init-scripts/files/mysql-5.1.67-init.d-r1 @@ -1,7 +1,7 @@ #!/sbin/runscript -# Copyright 1999-2011 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/files/mysql-5.1.53-init.d,v 1.1 2011/01/13 20:06:06 robbat2 Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/files/mysql-5.1.67-init.d-r1,v 1.1 2014/05/16 01:49:43 grknight Exp $ depend() { use net.lo @@ -25,12 +25,12 @@ mysql_svcname() { start() { # Check for old conf.d variables that mean migration was not yet done. - local varlist="${!mysql_slot_*} ${!MYSQL_BLOG_PID_FILE*} ${!STOPTIMEOUT*}" - varlist="${varlist// /}" + set | egrep -sq '^(mysql_slot_|MYSQL_BLOG_PID_FILE|STOPTIMEOUT)' + rc=$? # Yes, MYSQL_INIT_I_KNOW_WHAT_I_AM_DOING is a hidden variable. # It does have a use in testing, as it is possible to build a config file # that works with both the old and new init scripts simulateously. - if [ -n "${varlist}" -a -z "${MYSQL_INIT_I_KNOW_WHAT_I_AM_DOING}" ]; then + if [ "${rc}" = 0 -a -z "${MYSQL_INIT_I_KNOW_WHAT_I_AM_DOING}" ]; then eerror "You have not updated your conf.d for the new mysql-init-scripts-2 revamp." eerror "Not proceeding because it may be dangerous." return 1 @@ -59,20 +59,24 @@ start() { fi if [ ! -d "${datadir}"/mysql ] ; then - eerror "You don't appear to have the mysql database installed yet." - eerror "Please run /usr/bin/mysql_install_db to have this done..." + # find which package is installed to report an error + local EROOT=$(portageq envvar EROOT) + local DBPKG_P=$(portageq match ${EROOT} $(portageq expand_virtual ${EROOT} virtual/mysql)) + if [[ -z ${DBPKG_P} ]] ; then + eerror "You don't appear to have a server package installed yet." + else + eerror "You don't appear to have the mysql database installed yet." + eerror "Please run \`emerge --config =${DBPKG_P}\` to have this done..." + fi return 1 fi local piddir="${pidfile%/*}" - if [ ! -d "$piddir" ] ; then - mkdir "$piddir" && \ - chown mysql "$piddir" - rc=$? - if [ $rc -ne 0 ]; then - eerror "Directory $piddir for pidfile does not exist and cannot be created" - return 1 - fi + checkpath -d --owner mysql:mysql --mode 0755 "$piddir" + rc=$? + if [ $rc -ne 0 ]; then + eerror "Directory $piddir for pidfile does not exist and cannot be created" + return 1 fi local startup_timeout=${STARTUP_TIMEOUT:-900} @@ -80,7 +84,7 @@ start() { local tmpnice="${NICE:+"--nicelevel "}${NICE}" local tmpionice="${IONICE:+"--ionice "}${IONICE}" start-stop-daemon \ - ${DEBUG/*/"--verbose"} \ + ${DEBUG:+"--verbose"} \ --start \ --exec "${basedir}"/sbin/mysqld \ --pidfile "${pidfile}" \ @@ -110,7 +114,7 @@ stop() { local stop_timeout=${STOP_TIMEOUT:-120} start-stop-daemon \ - ${DEBUG/*/"--verbose"} \ + ${DEBUG:+"--verbose"} \ --stop \ --exec "${basedir}"/sbin/mysqld \ --pidfile "${pidfile}" \ diff --git a/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r3.ebuild b/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r3.ebuild deleted file mode 100644 index 1b962c89fa10..000000000000 --- a/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r3.ebuild +++ /dev/null @@ -1,56 +0,0 @@ -# Copyright 1999-2013 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r3.ebuild,v 1.13 2013/05/20 17:59:08 ago Exp $ - -DESCRIPTION="Gentoo MySQL init scripts." -HOMEPAGE="http://www.gentoo.org/" -SRC_URI="" - -LICENSE="GPL-2" -SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd" -IUSE="" - -DEPEND="" -# This _will_ break with MySQL 5.0, 4.x, 3.x -# It also NEEDS openrc for the save_options/get_options builtins. -RDEPEND="!<dev-db/mysql-5.1 - sys-apps/openrc" - -src_install() { - newconfd "${FILESDIR}/mysql-5.1.53-conf.d" "mysql" - newinitd "${FILESDIR}/mysql-5.1.67-init.d" "mysql" - - insinto /etc/logrotate.d - newins "${FILESDIR}/logrotate.mysql" "mysql" -} - -pkg_postinst() { - grep -sq mysql_slot "${ROOT}"/etc/conf.d/mysql - old_conf_present=$? - grep -sq get_slot_config "${ROOT}"/etc/init.d/mysql - old_init_present=$? - - egrep -sq 'MY_CNF|MY_ARGS|(STARTUP|STOP)_TIMEOUT' "${ROOT}"/etc/conf.d/mysql - new_conf_present=$? - egrep -sq 'MY_ARGS|STOP_TIMEOUT' "${ROOT}"/etc/init.d/mysql - new_init_present=$? - - einfo "Please note that if you are using multiple internal 'slots' in the" - einfo "old conf.d file, you should use multiple init files now." - echo old $old_conf_present $old_init_present - echo new $new_conf_present $new_init_present - - # new scripts present - if [ $new_conf_present -eq 0 -a $new_init_present -eq 0 -a \ - $old_conf_present -eq 1 -a $old_init_present -eq 1 ]; then - : - elif [ $old_conf_present -eq 0 -a $old_init_present -eq 0 -a \ - $new_conf_present -eq 1 -a $new_init_present -eq 1 ]; then - ewarn "Old /etc/init.d/mysql and /etc/conf.d/mysql still present!" - ewarn "Update both of those files to the new versions!" - else - eerror "DANGER, mixed update of /etc/init.d/mysql and /etc/conf.d/mysql" - eerror "detected! You must update BOTH to the new versions" - fi -} diff --git a/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r2.ebuild b/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r7.ebuild index cbd5419e1879..5fea798eef67 100644 --- a/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r2.ebuild +++ b/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r7.ebuild @@ -1,6 +1,10 @@ -# Copyright 1999-2013 Gentoo Foundation +# Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r2.ebuild,v 1.9 2013/04/30 01:01:59 jer Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r7.ebuild,v 1.1 2014/05/16 01:49:43 grknight Exp $ + +EAPI=5 + +inherit systemd DESCRIPTION="Gentoo MySQL init scripts." HOMEPAGE="http://www.gentoo.org/" @@ -8,18 +12,26 @@ SRC_URI="" LICENSE="GPL-2" SLOT="0" -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~sparc-fbsd ~x86-fbsd" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd" IUSE="" DEPEND="" # This _will_ break with MySQL 5.0, 4.x, 3.x # It also NEEDS openrc for the save_options/get_options builtins. -RDEPEND="!<dev-db/mysql-5.1 - sys-apps/openrc" +RDEPEND="!<dev-db/mysql-5.1" +# Need to set S due to PMS saying we need it existing, but no SRC_URI +S=${WORKDIR} src_install() { newconfd "${FILESDIR}/mysql-5.1.53-conf.d" "mysql" - newinitd "${FILESDIR}/mysql-5.1.53-init.d" "mysql" + newinitd "${FILESDIR}/mysql-5.1.67-init.d-r1" "mysql" + + # systemd unit installation + exeinto /usr/libexec + doexe "${FILESDIR}"/mysqld-wait-ready + systemd_dounit "${FILESDIR}/mysqld.service" + systemd_newunit "${FILESDIR}/mysqld_at.service" "mysqld@.service" + systemd_dotmpfilesd "${FILESDIR}/mysql.conf" insinto /etc/logrotate.d newins "${FILESDIR}/logrotate.mysql" "mysql" |