Gentoo Archives: gentoo-commits

From: "Pacho Ramos (pacho)" <pacho@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-db/mysql-init-scripts: mysql-init-scripts-2.0_pre1-r4.ebuild ChangeLog
Date: Tue, 03 Sep 2013 18:49:55
Message-Id: 20130903184949.0C8802004C@flycatcher.gentoo.org
1 pacho 13/09/03 18:49:48
2
3 Modified: ChangeLog
4 Added: mysql-init-scripts-2.0_pre1-r4.ebuild
5 Log:
6 Add systemd support (#466084)
7
8 (Portage version: 2.2.1/cvs/Linux x86_64, signed Manifest commit with key A188FBD4)
9
10 Revision Changes Path
11 1.28 dev-db/mysql-init-scripts/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog?rev=1.28&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog?rev=1.28&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog?r1=1.27&r2=1.28
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog,v
20 retrieving revision 1.27
21 retrieving revision 1.28
22 diff -u -r1.27 -r1.28
23 --- ChangeLog 20 May 2013 17:59:08 -0000 1.27
24 +++ ChangeLog 3 Sep 2013 18:49:48 -0000 1.28
25 @@ -1,6 +1,13 @@
26 # ChangeLog for dev-db/mysql-init-scripts
27 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog,v 1.27 2013/05/20 17:59:08 ago Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/ChangeLog,v 1.28 2013/09/03 18:49:48 pacho Exp $
30 +
31 +*mysql-init-scripts-2.0_pre1-r4 (03 Sep 2013)
32 +
33 + 03 Sep 2013; Pacho Ramos <pacho@g.o> +files/mysql.conf,
34 + +files/mysqld-prepare-db-dir, +files/mysqld-wait-ready, +files/mysqld.service,
35 + +files/mysqld_at.service, +mysql-init-scripts-2.0_pre1-r4.ebuild:
36 + Add systemd support (#466084)
37
38 20 May 2013; Agostino Sarubbo <ago@g.o>
39 mysql-init-scripts-2.0_pre1-r3.ebuild:
40
41
42
43 1.1 dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r4.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r4.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r4.ebuild?rev=1.1&content-type=text/plain
47
48 Index: mysql-init-scripts-2.0_pre1-r4.ebuild
49 ===================================================================
50 # Copyright 1999-2013 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/dev-db/mysql-init-scripts/mysql-init-scripts-2.0_pre1-r4.ebuild,v 1.1 2013/09/03 18:49:48 pacho Exp $
53
54 inherit systemd
55
56 DESCRIPTION="Gentoo MySQL init scripts."
57 HOMEPAGE="http://www.gentoo.org/"
58 SRC_URI=""
59
60 LICENSE="GPL-2"
61 SLOT="0"
62 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
63 IUSE=""
64
65 DEPEND=""
66 # This _will_ break with MySQL 5.0, 4.x, 3.x
67 # It also NEEDS openrc for the save_options/get_options builtins.
68 RDEPEND="!<dev-db/mysql-5.1"
69
70 src_install() {
71 newconfd "${FILESDIR}/mysql-5.1.53-conf.d" "mysql"
72 newinitd "${FILESDIR}/mysql-5.1.67-init.d" "mysql"
73
74 # systemd unit installation
75 exeinto /usr/libexec
76 doexe "${FILESDIR}"/{mysqld-prepare-db-dir,mysqld-wait-ready}
77 systemd_dounit "${FILESDIR}/mysqld.service"
78 systemd_newunit "${FILESDIR}/mysqld_at.service" "mysqld@.service"
79 systemd_dotmpfilesd "${FILESDIR}/mysql.conf"
80
81 insinto /etc/logrotate.d
82 newins "${FILESDIR}/logrotate.mysql" "mysql"
83 }
84
85 pkg_postinst() {
86 grep -sq mysql_slot "${ROOT}"/etc/conf.d/mysql
87 old_conf_present=$?
88 grep -sq get_slot_config "${ROOT}"/etc/init.d/mysql
89 old_init_present=$?
90
91 egrep -sq 'MY_CNF|MY_ARGS|(STARTUP|STOP)_TIMEOUT' "${ROOT}"/etc/conf.d/mysql
92 new_conf_present=$?
93 egrep -sq 'MY_ARGS|STOP_TIMEOUT' "${ROOT}"/etc/init.d/mysql
94 new_init_present=$?
95
96 einfo "Please note that if you are using multiple internal 'slots' in the"
97 einfo "old conf.d file, you should use multiple init files now."
98 echo old $old_conf_present $old_init_present
99 echo new $new_conf_present $new_init_present
100
101 # new scripts present
102 if [ $new_conf_present -eq 0 -a $new_init_present -eq 0 -a \
103 $old_conf_present -eq 1 -a $old_init_present -eq 1 ]; then
104 :
105 elif [ $old_conf_present -eq 0 -a $old_init_present -eq 0 -a \
106 $new_conf_present -eq 1 -a $new_init_present -eq 1 ]; then
107 ewarn "Old /etc/init.d/mysql and /etc/conf.d/mysql still present!"
108 ewarn "Update both of those files to the new versions!"
109 else
110 eerror "DANGER, mixed update of /etc/init.d/mysql and /etc/conf.d/mysql"
111 eerror "detected! You must update BOTH to the new versions"
112 fi
113 }