games-board/cgoban: Port to C23

Fix sighandler definition to follow declaration, no behaviour
changes.

Closes: https://bugs.gentoo.org/944043
Signed-off-by: NHOrus <jy6x2b32pie9@yahoo.com>
Part-of: https://codeberg.org/gentoo/gentoo/pulls/245
Merges: https://codeberg.org/gentoo/gentoo/pulls/245
Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
NHOrus
2026-03-07 22:18:25 +03:00
committed by Sam James
parent c68ed27c2f
commit 4c6b67e91a
2 changed files with 64 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
# Copyright 1999-2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit autotools desktop
DESCRIPTION="Go-frontend with a large set of go-related services"
HOMEPAGE="https://cgoban1.sourceforge.net/"
SRC_URI="https://downloads.sourceforge.net/cgoban1/${P}.tar.gz"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
RDEPEND="
virtual/imagemagick-tools
x11-libs/libX11
x11-libs/libXt"
DEPEND="${RDEPEND}
x11-base/xorg-proto"
PATCHES=(
"${FILESDIR}"/${P}-cflags.patch
"${FILESDIR}"/${P}-sighandler.patch
)
src_prepare() {
default
cp cgoban_icon.png ${PN}.png || die
mv configure.{in,ac} || die
eautoreconf
}
src_install() {
default
doicon ${PN}.png
make_desktop_entry cgoban Cgoban
}

View File

@@ -0,0 +1,23 @@
https://bugs.gentoo.org/944043
Handler ignores arguments, adding ignored argument to signature
so it will conform to system one, is always correct.
--- a/src/main.c 2026-03-07 21:55:30.810539815 +0300
+++ b/src/main.c 2026-03-07 21:56:18.365294853 +0300
@@ -29,7 +29,7 @@
**********************************************************************/
static void stealth(int exitVal);
#if !DEBUG
-static RETSIGTYPE sigHandler();
+static RETSIGTYPE sigHandler(int);
#endif /* !DEBUG */
@@ -132,7 +132,7 @@
#if !DEBUG
-static RETSIGTYPE sigHandler() {
+static RETSIGTYPE sigHandler(int) {
fprintf(stderr, "Signal caught.\n");
abort();
}