commit:     6894d0e44432c48b498498cde2846acc43bb47be
Author:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 14 14:10:59 2025 +0000
Commit:     Ulrich Müller <ulm <AT> gentoo <DOT> org>
CommitDate: Sun Feb 16 07:22:06 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6894d0e4

app-misc/mosquitto: Port to ver_replacing

Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org>

 app-misc/mosquitto/mosquitto-2.0.20.ebuild | 28 +++++++++++++---------------
 1 file changed, 13 insertions(+), 15 deletions(-)

diff --git a/app-misc/mosquitto/mosquitto-2.0.20.ebuild 
b/app-misc/mosquitto/mosquitto-2.0.20.ebuild
index 198216be0635..2bbf86d3af31 100644
--- a/app-misc/mosquitto/mosquitto-2.0.20.ebuild
+++ b/app-misc/mosquitto/mosquitto-2.0.20.ebuild
@@ -1,10 +1,10 @@
-# Copyright 1999-2024 Gentoo Authors
+# Copyright 1999-2025 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=8
 PYTHON_COMPAT=( python3_{10..13} )
 
-inherit python-any-r1 systemd toolchain-funcs
+inherit eapi9-ver python-any-r1 systemd toolchain-funcs
 
 DESCRIPTION="An Open Source MQTT v3 Broker"
 HOMEPAGE="https://mosquitto.org/ https://github.com/eclipse/mosquitto";
@@ -118,17 +118,15 @@ src_install() {
 }
 
 pkg_postinst() {
-       for v in ${REPLACING_VERSIONS}; do
-               if [[ $(ver_cut 1 "$v") -lt 2 ]]; then
-                       elog
-                       elog "Please read the migration guide at:"
-                       elog 
"https://mosquitto.org/documentation/migrating-to-2-0/";
-                       elog
-                       elog "If you use Lets Encrypt TLS certificates, take 
note of"
-                       elog "the changes required to run the daemon as the 
unprivileged"
-                       elog "mosquitto user. The mosquitto-copy.sh script has 
been"
-                       elog "installed to /usr/share/mosquitto/ for your 
convenience."
-                       elog
-               fi
-       done
+       if ver_replacing -lt 2; then
+               elog
+               elog "Please read the migration guide at:"
+               elog "https://mosquitto.org/documentation/migrating-to-2-0/";
+               elog
+               elog "If you use Lets Encrypt TLS certificates, take note of"
+               elog "the changes required to run the daemon as the 
unprivileged"
+               elog "mosquitto user. The mosquitto-copy.sh script has been"
+               elog "installed to /usr/share/mosquitto/ for your convenience."
+               elog
+       fi
 }

Reply via email to