mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-22 13:33:32 -04:00
gui-apps/someblocks: fix build with GCC 15
Closes: https://bugs.gentoo.org/945237 Signed-off-by: Takuya Wakazono <pastalian46@gmail.com>
This commit is contained in:
29
gui-apps/someblocks/files/someblocks-1.0.1-c23.patch
Normal file
29
gui-apps/someblocks/files/someblocks-1.0.1-c23.patch
Normal file
@@ -0,0 +1,29 @@
|
|||||||
|
https://bugs.gentoo.org/945237
|
||||||
|
https://lists.sr.ht/~raphi/public-inbox/patches/56817
|
||||||
|
C23 compatibility patch.
|
||||||
|
--- a/someblocks.c
|
||||||
|
+++ b/someblocks.c
|
||||||
|
@@ -34,7 +34,7 @@ void setupsignals();
|
||||||
|
void sighandler(int signum);
|
||||||
|
int getstatus(char *str, char *last);
|
||||||
|
void statusloop();
|
||||||
|
-void termhandler();
|
||||||
|
+void termhandler(int signum);
|
||||||
|
void pstdout();
|
||||||
|
void psomebar();
|
||||||
|
static void (*writestatus) () = psomebar;
|
||||||
|
@@ -178,12 +178,12 @@ void sighandler(int signum)
|
||||||
|
writestatus();
|
||||||
|
}
|
||||||
|
|
||||||
|
-void termhandler()
|
||||||
|
+void termhandler(int signum)
|
||||||
|
{
|
||||||
|
statusContinue = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
-void sigpipehandler()
|
||||||
|
+void sigpipehandler(int signum)
|
||||||
|
{
|
||||||
|
close(somebarFd);
|
||||||
|
somebarFd = -1;
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
# Copyright 2022 Gentoo Authors
|
# Copyright 2022-2025 Gentoo Authors
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
EAPI=7
|
EAPI=8
|
||||||
|
|
||||||
inherit savedconfig
|
inherit savedconfig
|
||||||
|
|
||||||
@@ -13,21 +13,22 @@ LICENSE="ISC"
|
|||||||
SLOT="0"
|
SLOT="0"
|
||||||
KEYWORDS="~amd64"
|
KEYWORDS="~amd64"
|
||||||
|
|
||||||
|
PATCHES=(
|
||||||
|
# bug #945237
|
||||||
|
"${FILESDIR}/${P}-c23.patch"
|
||||||
|
)
|
||||||
|
|
||||||
src_prepare() {
|
src_prepare() {
|
||||||
default
|
default
|
||||||
sed -i -e 's:$(LDFLAGS):$(CPPFLAGS) $(CFLAGS) $(LDFLAGS):' Makefile \
|
sed -i -e 's:$(LDFLAGS):$(CPPFLAGS) $(CFLAGS) $(LDFLAGS):' Makefile \
|
||||||
|| die "sed fix failed. Uh-oh..."
|
|| die "sed fix failed. Uh-oh..."
|
||||||
# prevent compilation in install phase
|
# prevent compilation in install phase
|
||||||
sed -i -e "s/install: output/install:/g" Makefile
|
sed -i -e "s/install: output/install:/g" Makefile || die
|
||||||
restore_config blocks.h
|
restore_config blocks.h
|
||||||
}
|
}
|
||||||
|
|
||||||
src_compile() {
|
|
||||||
emake output
|
|
||||||
}
|
|
||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
emake PREFIX="${ED}/usr" install
|
emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install
|
||||||
|
|
||||||
einstalldocs
|
einstalldocs
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
# Copyright 2022 Gentoo Authors
|
# Copyright 2022-2025 Gentoo Authors
|
||||||
# Distributed under the terms of the GNU General Public License v2
|
# Distributed under the terms of the GNU General Public License v2
|
||||||
|
|
||||||
EAPI=7
|
EAPI=8
|
||||||
|
|
||||||
inherit savedconfig git-r3
|
inherit savedconfig git-r3
|
||||||
|
|
||||||
@@ -16,12 +16,15 @@ RDEPEND="${DEPEND}"
|
|||||||
|
|
||||||
src_prepare() {
|
src_prepare() {
|
||||||
default
|
default
|
||||||
|
sed -i -e 's:$(LDFLAGS):$(CPPFLAGS) $(CFLAGS) $(LDFLAGS):' Makefile \
|
||||||
|
|| die "sed fix failed. Uh-oh..."
|
||||||
|
# prevent compilation in install phase
|
||||||
|
sed -i -e "s/install: output/install:/g" Makefile || die
|
||||||
restore_config blocks.h
|
restore_config blocks.h
|
||||||
}
|
}
|
||||||
|
|
||||||
src_install() {
|
src_install() {
|
||||||
emake PREFIX="${ED}/usr" install
|
emake DESTDIR="${D}" PREFIX="${EPREFIX}/usr" install
|
||||||
|
|
||||||
einstalldocs
|
einstalldocs
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user