commit:     f6ea7b4723c8c1aeae652b9cf342bc0f8c1fe2ff
Author:     Henning Schild <henning <AT> hennsch <DOT> de>
AuthorDate: Sun Nov 23 09:28:26 2025 +0000
Commit:     Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Jan 10 13:08:15 2026 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f6ea7b47

net-print/gtklp: update to 1.3.4

Signed-off-by: Henning Schild <henning <AT> hennsch.de>
Part-of: https://github.com/gentoo/gentoo/pull/44738
Closes: https://github.com/gentoo/gentoo/pull/44738
Signed-off-by: Sam James <sam <AT> gentoo.org>

 net-print/gtklp/Manifest                          |  1 +
 net-print/gtklp/files/gtklp-1.3.4-formatsec.patch | 38 ++++++++++++++++
 net-print/gtklp/gtklp-1.3.4.ebuild                | 53 +++++++++++++++++++++++
 3 files changed, 92 insertions(+)

diff --git a/net-print/gtklp/Manifest b/net-print/gtklp/Manifest
index 2588640a56d5..ab61bd51c3d6 100644
--- a/net-print/gtklp/Manifest
+++ b/net-print/gtklp/Manifest
@@ -1,2 +1,3 @@
 DIST gtklp-1.3.1.src.tar.gz 641805 BLAKE2B 
fe5406dc9e95d6faa1335ce44c5e2cf9c0cf2db711c68962f64d88a403e18ac4da2c640467c62f6af256ca73370a3ef6db305ce75a4b7fcc9918d2c8825ffaaf
 SHA512 
22d8e519d5d767add9d786bb9d4e288fffad929e8cac5b0125f654f520e1a466cf0d32bb2f6fbc0804085748403436adc5850b805531dbc971b91eb05627ae70
+DIST gtklp-1.3.4.src.tar.gz 678888 BLAKE2B 
6108be518d2ccc9dd88fd98c195d6f02626809128401b56845973963491c09028b6eb5d7a6b8047c3b4c4869af310aea547284c2958c1fa48205b7050961b4be
 SHA512 
1aff481214b01f9d5dbacf5e23ec19a8424c4d0ae4e6489de06cdb708fc5fbc9bcff9ac8cb70c87983572023397534c0f3be3cbf732c352757efcc0d43f1165e
 DIST gtklp-logo.xpm.gz 2254 BLAKE2B 
6ba85919472c0018cb77c89b6d5058e68845d94c2baa941d43d55a9a58b33f9347cdd8e3449afc3f692ae0b4d1bcb73fb0159b372b641537420e7131fcd9d703
 SHA512 
24fd320bb1fd533d5f539ad5aa22661a2c923c4d6012b7d908a7a8311dcd179f2c7f02a88d52289d659ad89ce63ab40956725051b7dbe14ed23eb3a62e6c9240

diff --git a/net-print/gtklp/files/gtklp-1.3.4-formatsec.patch 
b/net-print/gtklp/files/gtklp-1.3.4-formatsec.patch
new file mode 100644
index 000000000000..d09ab9e2bb2b
--- /dev/null
+++ b/net-print/gtklp/files/gtklp-1.3.4-formatsec.patch
@@ -0,0 +1,38 @@
+https://sources.debian.org/src/gtklp/1.3.4-4/debian/patches/0005-fix-format-security.patch
+
+From: Boyuan Yang <[email protected]>
+Date: Sun, 23 Jan 2022 16:19:15 -0500
+Subject: fix format-security
+
+---
+ libgtklp/libgtklp.c | 8 ++++----
+ 1 file changed, 4 insertions(+), 4 deletions(-)
+
+diff --git a/libgtklp/libgtklp.c b/libgtklp/libgtklp.c
+index f380a9c..cf4ad06 100644
+--- a/libgtklp/libgtklp.c
++++ b/libgtklp/libgtklp.c
+@@ -939,9 +939,9 @@ void exitOnError(char *gerror1, char *gerror2, int 
exitcode)
+               gtk_widget_show(pixmapwid);
+ 
+               if (strlen(gerror2) == 0)
+-                      snprintf(tmplabel, (size_t) MAXLINE, gerror1);
++                      snprintf(tmplabel, (size_t) MAXLINE, "%s", gerror1);
+               else
+-                      snprintf(tmplabel, (size_t) MAXLINE, gerror1, gerror2);
++                      snprintf(tmplabel, (size_t) MAXLINE, "%s\n%s", gerror1, 
gerror2);
+               label = gtk_label_new(tmplabel);
+               gtk_box_pack_end(GTK_BOX(hbox), label, FALSE, FALSE,
+                                FRAME_SPACING_V);
+@@ -973,9 +973,9 @@ void exitOnError(char *gerror1, char *gerror2, int 
exitcode)
+ #endif
+       } else {
+               if (strlen(gerror2) == 0)
+-                      g_warning(gerror1);
++                      g_warning("%s", gerror1);
+               else
+-                      g_warning(gerror1, gerror2);
++                      g_warning("%s\n%s", gerror1, gerror2);
+       }
+       exit(exitcode);
+ }

diff --git a/net-print/gtklp/gtklp-1.3.4.ebuild 
b/net-print/gtklp/gtklp-1.3.4.ebuild
new file mode 100644
index 000000000000..d0aad0b910b8
--- /dev/null
+++ b/net-print/gtklp/gtklp-1.3.4.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools desktop flag-o-matic xdg
+
+DESCRIPTION="A GUI for cupsd"
+HOMEPAGE="https://gtklp.sirtobi.com/";
+SRC_URI="
+       
https://downloads.sourceforge.net/project/${PN}/${PN}/${PV}/${P}.src.tar.gz
+       
https://downloads.sourceforge.net/project/${PN}/enhancements/icons/logo.xpm.gz 
-> ${PN}-logo.xpm.gz
+"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~sparc ~x86"
+IUSE="nls ssl"
+
+RDEPEND="
+       net-print/cups
+       x11-libs/gtk+:2
+       nls? ( sys-devel/gettext )
+       ssl? ( dev-libs/openssl:0= )"
+DEPEND="${RDEPEND}"
+BDEPEND="virtual/pkgconfig"
+
+PATCHES=( "${FILESDIR}/${P}-formatsec.patch" )
+
+src_prepare() {
+       default
+       sed -e '/DEF_BROWSER_CMD/{s:netscape:firefox:}' \
+               -e 
'/DEF_HELP_HOME/{s:631/sum.html#STANDARD_OPTIONS:631/help/:}' \
+               -i include/defaults.h || die
+       eautoreconf
+}
+
+src_configure() {
+       append-cflags -fcommon
+       econf \
+               $(use_enable nls) \
+               $(use_enable ssl) \
+               --enable-forte #369003
+}
+
+src_install() {
+       default
+
+       dodoc USAGE
+       doicon "${WORKDIR}"/"${PN}"-logo.xpm
+       make_desktop_entry 'gtklp -i' "${PN} -- Print files via CUPS" 
"${PN}"-logo 'System;HardwareSettings;Settings;Printing'
+       make_desktop_entry "${PN}"q "${PN}q -- CUPS queue manager" "${PN}"-logo 
'System;HardwareSettings;Settings;Printing'
+}

Reply via email to