commit:     66b99defd2edd7aa27a57629a49d51254ad9857b
Author:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 13 14:21:57 2026 +0000
Commit:     Ionen Wolkens <ionen <AT> gentoo <DOT> org>
CommitDate: Fri Feb 13 14:28:34 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=66b99def

x11-misc/tint2: tidy, adjust dependencies, fix for cmake4+glib2.76

Also fix BetterCompressionUri, and drop USE=battery (always enabled,
it has no dependencies and adds very little to the build).

wrt bug #901775, personally never had 17.0.2 crash with glib-2.76+
despite using it with tint2 for ~3 years (don't know for 17.1), but
it may be specific to configuration/usage and having the 17.0.2 fix
doesn't seem to hurt.

Closes: https://bugs.gentoo.org/901775
Closes: https://bugs.gentoo.org/957928
Signed-off-by: Ionen Wolkens <ionen <AT> gentoo.org>

 x11-misc/tint2/Manifest                          |  2 +-
 x11-misc/tint2/files/tint2-17.0.2-cmake4.patch   | 15 +++++++
 x11-misc/tint2/files/tint2-17.0.2-glib2.76.patch | 19 ++++++++
 x11-misc/tint2/metadata.xml                      |  1 -
 x11-misc/tint2/tint2-17.0.2-r1.ebuild            | 56 ++++++++++++++++++++++++
 x11-misc/tint2/tint2-17.0.2.ebuild               | 48 --------------------
 6 files changed, 91 insertions(+), 50 deletions(-)

diff --git a/x11-misc/tint2/Manifest b/x11-misc/tint2/Manifest
index 8512b2b286da..86c5592fba91 100644
--- a/x11-misc/tint2/Manifest
+++ b/x11-misc/tint2/Manifest
@@ -1 +1 @@
-DIST tint2-v17.0.2.tar.gz 553734 BLAKE2B 
73cd89757963f1a3c3460a2e8e61891e77eb12b9809590dbbbc00df00d03e82d33d6175c7e3ff4623a3390e35fe1530263915b4574dedfd46d9401fbc90d769f
 SHA512 
9bfdf9ba33183ed60b95f73e58d9c1c22af83e9973a0e07ff2825d66d19c7103364426753a07eaecd4dbca278dfc6e22737bc6ce38d9b577b65f672f146e7aa2
+DIST tint2-v17.0.2.tar.bz2 405654 BLAKE2B 
0693f5f1b13dcfc58a6140bb9ff4a0607704f82ea0851ee9a4fdbdc94f3490ef809632125db45bb29cf2c33f4a655a0836d418e89a281977d67019fb4836fac8
 SHA512 
2b309fd1ab01e5176cc95e0651f28224b158c2bafd58cfff19840b0f8e880e9f4dcefeff32bc66d5fac11d932d4ee668ea7ddd7bab860f9edcfcdb7074e0e0ed

diff --git a/x11-misc/tint2/files/tint2-17.0.2-cmake4.patch 
b/x11-misc/tint2/files/tint2-17.0.2-cmake4.patch
new file mode 100644
index 000000000000..b429dc6b3b37
--- /dev/null
+++ b/x11-misc/tint2/files/tint2-17.0.2-cmake4.patch
@@ -0,0 +1,15 @@
+https://bugs.gentoo.org/957928
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -1,3 +1,3 @@
++cmake_minimum_required( VERSION 3.16...4.1 )
+ project( tint2 )
+-cmake_minimum_required( VERSION 2.8.5 )
+ 
+--- a/src/tint2conf/CMakeLists.txt
++++ b/src/tint2conf/CMakeLists.txt
+@@ -1,3 +1,3 @@
++cmake_minimum_required(VERSION 3.16...4.1)
+ project(tint2conf)
+-cmake_minimum_required(VERSION 2.6)
+ 

diff --git a/x11-misc/tint2/files/tint2-17.0.2-glib2.76.patch 
b/x11-misc/tint2/files/tint2-17.0.2-glib2.76.patch
new file mode 100644
index 000000000000..63662489df27
--- /dev/null
+++ b/x11-misc/tint2/files/tint2-17.0.2-glib2.76.patch
@@ -0,0 +1,19 @@
+https://bugs.gentoo.org/901775
+--- a/src/util/uevent.c
++++ b/src/util/uevent.c
+@@ -158,5 +158,8 @@
+     struct uevent *ev = uevent_new(buf, len);
+     if (ev) {
+-        for (GList *l = notifiers; l; l = l->next) {
++        /* we might remove elements in the callback so a copy is needed */
++        GList *list = g_list_copy(notifiers);
++
++        for (GList *l = list; l; l = l->next) {
+             struct uevent_notify *nb = l->data;
+ 
+@@ -170,4 +173,5 @@
+         }
+ 
++        g_list_free(list);
+         uevent_free(ev);
+     }

diff --git a/x11-misc/tint2/metadata.xml b/x11-misc/tint2/metadata.xml
index c1bbe626c731..e0f67f18a3ef 100644
--- a/x11-misc/tint2/metadata.xml
+++ b/x11-misc/tint2/metadata.xml
@@ -6,7 +6,6 @@
                <name>Ionen Wolkens</name>
        </maintainer>
        <use>
-               <flag name="battery">Enable battery status plugin</flag>
                <flag name="tint2conf">Build/Install tint2conf as well</flag>
        </use>
        <upstream>

diff --git a/x11-misc/tint2/tint2-17.0.2-r1.ebuild 
b/x11-misc/tint2/tint2-17.0.2-r1.ebuild
new file mode 100644
index 000000000000..b9bc0f042979
--- /dev/null
+++ b/x11-misc/tint2/tint2-17.0.2-r1.ebuild
@@ -0,0 +1,56 @@
+# Copyright 1999-2026 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit cmake xdg
+
+DESCRIPTION="Lightweight panel/taskbar for Linux"
+HOMEPAGE="https://gitlab.com/o9000/tint2/";
+SRC_URI="https://gitlab.com/o9000/tint2/-/archive/v${PV}/${PN}-v${PV}.tar.bz2";
+S=${WORKDIR}/${PN}-v${PV}
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="amd64 ~arm64 ~ppc x86"
+IUSE="startup-notification svg tint2conf"
+
+RDEPEND="
+       dev-libs/glib:2
+       media-libs/imlib2[X,png]
+       x11-libs/cairo[X]
+       x11-libs/libX11
+       x11-libs/libXcomposite
+       x11-libs/libXdamage
+       x11-libs/libXext
+       x11-libs/libXinerama
+       x11-libs/libXrandr
+       x11-libs/libXrender
+       x11-libs/pango
+       startup-notification? ( x11-libs/startup-notification )
+       svg? (
+               gnome-base/librsvg:2
+               x11-libs/gdk-pixbuf:2
+       )
+       tint2conf? (
+               x11-libs/gdk-pixbuf:2
+               x11-libs/gtk+:3
+       )
+"
+DEPEND="${RDEPEND}"
+
+PATCHES=(
+       "${FILESDIR}"/${P}-cmake4.patch
+       "${FILESDIR}"/${P}-glib2.76.patch
+)
+
+src_configure() {
+       local mycmakeargs=(
+               -Ddocdir="${EPREFIX}"/usr/share/doc/${PF}
+               -DENABLE_RSVG=$(usex svg)
+               -DENABLE_SN=$(usex startup-notification)
+               -DENABLE_TINT2CONF=$(usex tint2conf)
+       )
+
+       cmake_src_configure
+}

diff --git a/x11-misc/tint2/tint2-17.0.2.ebuild 
b/x11-misc/tint2/tint2-17.0.2.ebuild
deleted file mode 100644
index bf1274bc041a..000000000000
--- a/x11-misc/tint2/tint2-17.0.2.ebuild
+++ /dev/null
@@ -1,48 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit cmake xdg
-
-DESCRIPTION="Lightweight panel/taskbar for Linux"
-HOMEPAGE="https://gitlab.com/o9000/tint2";
-SRC_URI="https://gitlab.com/o9000/${PN}/-/archive/v${PV}/${PN}-v${PV}.tar.gz";
-S=${WORKDIR}/${PN}-v${PV}
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="amd64 ~arm64 ~ppc x86"
-IUSE="battery startup-notification svg tint2conf"
-
-DEPEND="
-       dev-libs/glib:2
-       svg? ( gnome-base/librsvg:2 )
-       >=media-libs/imlib2-1.4.2[X,png]
-       x11-libs/cairo[X]
-       x11-libs/pango
-       tint2conf? ( x11-libs/gtk+:3 )
-       x11-libs/libX11
-       x11-libs/libXcomposite
-       x11-libs/libXdamage
-       x11-libs/libXinerama
-       >=x11-libs/libXrandr-1.3
-       x11-libs/libXrender
-       startup-notification? ( x11-libs/startup-notification )
-"
-RDEPEND="${DEPEND}"
-
-src_prepare() {
-       cmake_src_prepare
-}
-
-src_configure() {
-       local mycmakeargs=(
-               -Ddocdir="${EPREFIX}/usr/share/doc/${PF}"
-               -DENABLE_BATTERY="$(usex battery)"
-               -DENABLE_TINT2CONF="$(usex tint2conf)"
-               -DENABLE_SN="$(usex startup-notification)"
-               -DENABLE_RSVG="$(usex svg)"
-       )
-       cmake_src_configure
-}

Reply via email to