[packages/irssi] fix build with recent gcc versions (actual bugs)

atler atler at pld-linux.org
Sun May 11 19:23:14 CEST 2025


commit 210f0fcda05b02cfea901fae94070b41a62fbfa6
Author: Jan Palus <atler at pld-linux.org>
Date:   Sun May 11 19:02:17 2025 +0200

    fix build with recent gcc versions (actual bugs)

 irssi.spec  |  2 ++
 types.patch | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 54 insertions(+)
---
diff --git a/irssi.spec b/irssi.spec
index 011ff19..88dd4ae 100644
--- a/irssi.spec
+++ b/irssi.spec
@@ -41,6 +41,7 @@ Patch7:		%{name}-libs-nopoison.patch
 Patch8:		am.patch
 Patch9:		%{name}-idea-glib.patch
 Patch10:	%{name}-xmpp.patch
+Patch11:	types.patch
 URL:		http://www.irssi.org/
 BuildRequires:	autoconf
 BuildRequires:	automake
@@ -140,6 +141,7 @@ cd ..
 %endif
 %patch -P9 -p0
 %patch -P10 -p0
+%patch -P11 -p1
 
 # hack
 %{__sed} -i -e 's#\./libtool#%{_bindir}/libtool#g' 'configure.ac'
diff --git a/types.patch b/types.patch
new file mode 100644
index 0000000..272637c
--- /dev/null
+++ b/types.patch
@@ -0,0 +1,52 @@
+--- irssi-1.4.5/irssi-idea/src/plugin.c.orig	2002-05-17 08:57:32.000000000 +0200
++++ irssi-1.4.5/irssi-idea/src/plugin.c	2025-05-11 18:51:48.686520033 +0200
+@@ -96,6 +96,7 @@
+         const char *nickmode;
+ 	int for_me, print_channel, level;
+ 	char *color, *freemsg = NULL;
++	HILIGHT_REC *hilight;
+ 
+ 	g_return_if_fail(msg != NULL);
+ 
+@@ -108,8 +109,9 @@
+ 		msg = freemsg = expand_emphasis((WI_ITEM_REC *) chanrec, msg);
+ 
+ 	for_me = nick_match_msg(chanrec, msg, server->nick);
+-	color = for_me ? NULL :
++	hilight = for_me ? NULL :
+ 		hilight_match_nick(server, target, nick, address, MSGLEVEL_PUBLIC, msg);
++	color = (hilight == NULL) ? NULL : hilight_get_color(hilight);
+ 	nickmode = channel_get_nickmode(chanrec, server->nick);
+ 
+ 	level = MSGLEVEL_PUBLIC | (for_me || color != NULL ?
+--- irssi-1.4.5/irssi-idea/src/irc_api.c.orig	2025-05-11 18:54:29.972868221 +0200
++++ irssi-1.4.5/irssi-idea/src/irc_api.c	2025-05-11 18:58:08.103424787 +0200
+@@ -60,7 +60,7 @@
+ 	list = g_strsplit(msg, "|", -1);
+         ret = 0;
+ 
+-	if (strarray_length(list) == 7 && strcmp(list[1], "*E*") == 0) {
++	if (g_strv_length(list) == 7 && strcmp(list[1], "*E*") == 0) {
+ 		if (type != NULL)
+ 			*type = g_strdup(list[2]);
+ 
+@@ -371,7 +371,7 @@
+ 
+ 	// nick + \001 + %08lx(time) + \001 + message
+ 	list = g_strsplit(buf, "\001", -1);
+-	if (strarray_length(list) != 3) {
++	if (g_strv_length(list) != 3) {
+ 		g_strfreev(list);
+ 
+ 		if (message)
+--- irssi-1.4.5/irssi-xmpp/src/fe-common/xmpp-completion.c.orig	2016-03-18 15:07:32.000000000 +0100
++++ irssi-1.4.5/irssi-xmpp/src/fe-common/xmpp-completion.c	2025-05-11 19:01:06.516714276 +0200
+@@ -287,7 +287,7 @@
+ 		    chat_type, XMPP_PROTOCOL_NAME)
+ 		    || *channel_setup->name != '#')
+ 		    && g_ascii_strncasecmp(channel_setup->name, word, len) == 0
+-		    && glist_find_string(list, channel_setup->name) == NULL)
++		    && i_list_find_string(list, channel_setup->name) == NULL)
+ 			list = g_list_append(list,
+ 			    g_strdup(channel_setup->name));
+ 	}
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/irssi.git/commitdiff/210f0fcda05b02cfea901fae94070b41a62fbfa6



More information about the pld-cvs-commit mailing list