1 |
commit: 8bf890eba651c222a76f06d2fd3bfdb076cc811e |
2 |
Author: James Broadhead <jamesbroadhead <AT> gmail <DOT> com> |
3 |
AuthorDate: Fri Jan 27 20:11:04 2017 +0000 |
4 |
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Jan 27 22:12:19 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8bf890eb |
7 |
|
8 |
sys-apps/smartmontools: fix update warning |
9 |
|
10 |
- update warning about updating the drivedb, so that it notices the |
11 |
useflag |
12 |
- fix description so that it's short enough (adapted from the |
13 |
smartmontools website) -- repoman |
14 |
- quote some variables -- shellcheck |
15 |
- update the copy of the warning |
16 |
|
17 |
Fixes: https://bugs.gentoo.org/show_bug.cgi?id=587372 |
18 |
(cherry picked from commit 890093680d63a1b50d02e6408b55d4d748fcdbdb) |
19 |
Signed-off-by: Robin H. Johnson <robbat2 <AT> gentoo.org> |
20 |
Fixes: https://github.com/gentoo/gentoo/pull/3114 |
21 |
|
22 |
sys-apps/smartmontools/smartmontools-6.4-r1.ebuild | 12 ++++++------ |
23 |
sys-apps/smartmontools/smartmontools-6.4.ebuild | 4 ++-- |
24 |
sys-apps/smartmontools/smartmontools-6.5.ebuild | 21 +++++++++++++-------- |
25 |
sys-apps/smartmontools/smartmontools-9999.ebuild | 21 +++++++++++++-------- |
26 |
4 files changed, 34 insertions(+), 24 deletions(-) |
27 |
|
28 |
diff --git a/sys-apps/smartmontools/smartmontools-6.4-r1.ebuild b/sys-apps/smartmontools/smartmontools-6.4-r1.ebuild |
29 |
index 3746b94..a5f54df 100644 |
30 |
--- a/sys-apps/smartmontools/smartmontools-6.4-r1.ebuild |
31 |
+++ b/sys-apps/smartmontools/smartmontools-6.4-r1.ebuild |
32 |
@@ -14,7 +14,7 @@ else |
33 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~x64-macos" |
34 |
fi |
35 |
|
36 |
-DESCRIPTION="Self-Monitoring, Analysis and Reporting Technology System (S.M.A.R.T.) monitoring tools" |
37 |
+DESCRIPTION="Tools to monitor storage systems to provide advanced warning of disk degradation" |
38 |
HOMEPAGE="https://www.smartmontools.org" |
39 |
|
40 |
LICENSE="GPL-2" |
41 |
@@ -72,8 +72,8 @@ src_install() { |
42 |
newconfd "${FILESDIR}"/smartd.confd smartd |
43 |
|
44 |
# Move drivedb.h file out of PM's sight (bug #575292) |
45 |
- mv "${ED}"${db_path}/drivedb.h "${T}" || die |
46 |
- keepdir ${db_path} |
47 |
+ mv "${ED}${db_path}/drivedb.h" "${T}" || die |
48 |
+ keepdir "${db_path}" |
49 |
|
50 |
exeinto /etc/cron.monthly |
51 |
doexe "${FILESDIR}"/${PN}-update-drivedb |
52 |
@@ -85,14 +85,14 @@ pkg_postinst() { |
53 |
local db_path="/var/db/${PN}" |
54 |
|
55 |
if [[ -f "${db_path}/drivedb.h" ]] ; then |
56 |
- ewarn "WARNING! The drive database file has been replaced with the version that" |
57 |
- ewarn "got shipped with this release of ${PN}. You may want to update the" |
58 |
+ ewarn "WARNING! The existing copy of the drive database has been replaced with the version that" |
59 |
+ ewarn "was shipped with this release of ${PN}. You may want to update the" |
60 |
ewarn "database by running the following command as root:" |
61 |
ewarn "" |
62 |
ewarn "/usr/sbin/update-smart-drivedb" |
63 |
fi |
64 |
|
65 |
# Move drivedb.h to /var/db/${PN} (bug #575292) |
66 |
- mv "${T}"/drivedb.h ${db_path} || die |
67 |
+ mv "${T}"/drivedb.h "${db_path}" || die |
68 |
fi |
69 |
} |
70 |
|
71 |
diff --git a/sys-apps/smartmontools/smartmontools-6.4.ebuild b/sys-apps/smartmontools/smartmontools-6.4.ebuild |
72 |
index ca0d4ff..49a2c8c 100644 |
73 |
--- a/sys-apps/smartmontools/smartmontools-6.4.ebuild |
74 |
+++ b/sys-apps/smartmontools/smartmontools-6.4.ebuild |
75 |
@@ -14,8 +14,8 @@ else |
76 |
KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 sparc x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~x64-macos" |
77 |
fi |
78 |
|
79 |
-DESCRIPTION="Self-Monitoring, Analysis and Reporting Technology System (S.M.A.R.T.) monitoring tools" |
80 |
-HOMEPAGE="http://smartmontools.sourceforge.net/" |
81 |
+DESCRIPTION="Tools to monitor storage systems to provide advanced warning of disk degradation" |
82 |
+HOMEPAGE="https://www.smartmontools.org" |
83 |
|
84 |
LICENSE="GPL-2" |
85 |
SLOT="0" |
86 |
|
87 |
diff --git a/sys-apps/smartmontools/smartmontools-6.5.ebuild b/sys-apps/smartmontools/smartmontools-6.5.ebuild |
88 |
index 5d33f5c..ff73205 100644 |
89 |
--- a/sys-apps/smartmontools/smartmontools-6.5.ebuild |
90 |
+++ b/sys-apps/smartmontools/smartmontools-6.5.ebuild |
91 |
@@ -14,7 +14,7 @@ else |
92 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~x64-macos" |
93 |
fi |
94 |
|
95 |
-DESCRIPTION="Self-Monitoring, Analysis and Reporting Technology System (S.M.A.R.T.) monitoring tools" |
96 |
+DESCRIPTION="Tools to monitor storage systems to provide advanced warning of disk degradation" |
97 |
HOMEPAGE="https://www.smartmontools.org" |
98 |
|
99 |
LICENSE="GPL-2" |
100 |
@@ -68,13 +68,13 @@ src_install() { |
101 |
newinitd "${FILESDIR}"/smartd-r1.rc smartd |
102 |
newconfd "${FILESDIR}"/smartd.confd smartd |
103 |
|
104 |
- keepdir ${db_path} |
105 |
+ keepdir "${db_path}" |
106 |
if use update_drivedb ; then |
107 |
# Move drivedb.h file out of PM's sight (bug #575292) |
108 |
- mv "${ED}"${db_path}/drivedb.h "${T}" || die |
109 |
+ mv "${ED}${db_path}/drivedb.h" "${T}" || die |
110 |
|
111 |
exeinto /etc/cron.monthly |
112 |
- doexe "${FILESDIR}"/${PN}-update-drivedb |
113 |
+ doexe "${FILESDIR}/${PN}-update-drivedb" |
114 |
fi |
115 |
fi |
116 |
} |
117 |
@@ -84,16 +84,21 @@ pkg_postinst() { |
118 |
local db_path="/var/db/${PN}" |
119 |
|
120 |
if [[ -f "${db_path}/drivedb.h" ]] ; then |
121 |
- ewarn "WARNING! The drive database file has been replaced with the version that" |
122 |
- ewarn "got shipped with this release of ${PN}. You may want to update the" |
123 |
- ewarn "database by running the following command as root:" |
124 |
+ ewarn "WARNING! The existing copy of the drive database has been replaced with the version that" |
125 |
+ ewarn "was shipped with this release of ${PN}. You may want to update the" |
126 |
+ ewarn "database by: " |
127 |
+ |
128 |
+ if ! use update_drivedb ; then |
129 |
+ ewarn "re-merging ${PN} with USE='update_drivedb', then" |
130 |
+ fi |
131 |
+ ewarn "running the following command as root:" |
132 |
ewarn "" |
133 |
ewarn "/usr/sbin/update-smart-drivedb" |
134 |
fi |
135 |
|
136 |
if use update_drivedb ; then |
137 |
# Move drivedb.h to /var/db/${PN} (bug #575292) |
138 |
- mv "${T}"/drivedb.h ${db_path} || die |
139 |
+ mv "${T}"/drivedb.h "${db_path}" || die |
140 |
fi |
141 |
fi |
142 |
} |
143 |
|
144 |
diff --git a/sys-apps/smartmontools/smartmontools-9999.ebuild b/sys-apps/smartmontools/smartmontools-9999.ebuild |
145 |
index 5d33f5c..ff73205 100644 |
146 |
--- a/sys-apps/smartmontools/smartmontools-9999.ebuild |
147 |
+++ b/sys-apps/smartmontools/smartmontools-9999.ebuild |
148 |
@@ -14,7 +14,7 @@ else |
149 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd ~x86-freebsd ~amd64-linux ~arm-linux ~ia64-linux ~x86-linux ~x64-macos" |
150 |
fi |
151 |
|
152 |
-DESCRIPTION="Self-Monitoring, Analysis and Reporting Technology System (S.M.A.R.T.) monitoring tools" |
153 |
+DESCRIPTION="Tools to monitor storage systems to provide advanced warning of disk degradation" |
154 |
HOMEPAGE="https://www.smartmontools.org" |
155 |
|
156 |
LICENSE="GPL-2" |
157 |
@@ -68,13 +68,13 @@ src_install() { |
158 |
newinitd "${FILESDIR}"/smartd-r1.rc smartd |
159 |
newconfd "${FILESDIR}"/smartd.confd smartd |
160 |
|
161 |
- keepdir ${db_path} |
162 |
+ keepdir "${db_path}" |
163 |
if use update_drivedb ; then |
164 |
# Move drivedb.h file out of PM's sight (bug #575292) |
165 |
- mv "${ED}"${db_path}/drivedb.h "${T}" || die |
166 |
+ mv "${ED}${db_path}/drivedb.h" "${T}" || die |
167 |
|
168 |
exeinto /etc/cron.monthly |
169 |
- doexe "${FILESDIR}"/${PN}-update-drivedb |
170 |
+ doexe "${FILESDIR}/${PN}-update-drivedb" |
171 |
fi |
172 |
fi |
173 |
} |
174 |
@@ -84,16 +84,21 @@ pkg_postinst() { |
175 |
local db_path="/var/db/${PN}" |
176 |
|
177 |
if [[ -f "${db_path}/drivedb.h" ]] ; then |
178 |
- ewarn "WARNING! The drive database file has been replaced with the version that" |
179 |
- ewarn "got shipped with this release of ${PN}. You may want to update the" |
180 |
- ewarn "database by running the following command as root:" |
181 |
+ ewarn "WARNING! The existing copy of the drive database has been replaced with the version that" |
182 |
+ ewarn "was shipped with this release of ${PN}. You may want to update the" |
183 |
+ ewarn "database by: " |
184 |
+ |
185 |
+ if ! use update_drivedb ; then |
186 |
+ ewarn "re-merging ${PN} with USE='update_drivedb', then" |
187 |
+ fi |
188 |
+ ewarn "running the following command as root:" |
189 |
ewarn "" |
190 |
ewarn "/usr/sbin/update-smart-drivedb" |
191 |
fi |
192 |
|
193 |
if use update_drivedb ; then |
194 |
# Move drivedb.h to /var/db/${PN} (bug #575292) |
195 |
- mv "${T}"/drivedb.h ${db_path} || die |
196 |
+ mv "${T}"/drivedb.h "${db_path}" || die |
197 |
fi |
198 |
fi |
199 |
} |