mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
x11-plugins/asclock: fix gcc15
update HOMEPAGE (dead) apply a patch from opensuse to fix unprototyped functions. add missing rdep libXext and libX11, called in the ebuild. remove obsolete defs and unnecessary flags Closes: https://bugs.gentoo.org/944001 Signed-off-by: Nicolas PARLANT <nicolas.parlant@parhuet.fr> Part-of: https://github.com/gentoo/gentoo/pull/43504 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
committed by
Sam James
parent
e238ff6cd7
commit
d922c3edc3
64
x11-plugins/asclock/asclock-2.0.12-r5.ebuild
Normal file
64
x11-plugins/asclock/asclock-2.0.12-r5.ebuild
Normal file
@@ -0,0 +1,64 @@
|
||||
# Copyright 1999-2025 Gentoo Authors
|
||||
# Distributed under the terms of the GNU General Public License v2
|
||||
|
||||
EAPI=8
|
||||
|
||||
inherit edo toolchain-funcs
|
||||
|
||||
DESCRIPTION="Clock applet for AfterStep"
|
||||
HOMEPAGE="http://wiki.afterstep.org/index.php?title=AfterStep_Applets_DataBase#asclock"
|
||||
SRC_URI="http://www.tigr.net/afterstep/download/asclock/${P}.tar.gz"
|
||||
|
||||
LICENSE="GPL-2"
|
||||
SLOT="0"
|
||||
KEYWORDS="~amd64 ~mips ~ppc ~sparc ~x86 ~amd64-linux ~x86-linux ~x64-solaris"
|
||||
|
||||
DEPEND="
|
||||
x11-libs/libX11
|
||||
x11-libs/libXext
|
||||
x11-libs/libXpm
|
||||
"
|
||||
RDEPEND="${DEPEND}"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${PN}-gcc41.patch
|
||||
"${FILESDIR}"/${P}-fno-common.patch
|
||||
"${FILESDIR}"/${P}-fix-implicit-func-decl.patch
|
||||
"${FILESDIR}"/${P}-fix_gcc15.patch
|
||||
)
|
||||
|
||||
src_prepare() {
|
||||
default
|
||||
|
||||
ln -s themes/classic default_theme || die
|
||||
}
|
||||
|
||||
src_configure() {
|
||||
:;
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
local x
|
||||
for x in asclock parser symbols config; do
|
||||
edo $(tc-getCC) \
|
||||
${CPPFLAGS} ${CFLAGS} ${ASFLAGS} \
|
||||
-c -o ${x}.o ${x}.c
|
||||
done
|
||||
|
||||
edo $(tc-getCC) \
|
||||
${LDFLAGS} \
|
||||
-o asclock \
|
||||
asclock.o parser.o symbols.o config.o \
|
||||
$($(tc-getPKG_CONFIG) --print-errors --libs x11 xext xpm)
|
||||
}
|
||||
|
||||
src_install() {
|
||||
dobin asclock
|
||||
local themesdir="/usr/share/${PN}/themes"
|
||||
insinto ${themesdir}
|
||||
doins -r themes/*
|
||||
dodoc README README.THEMES TODO
|
||||
cd "${ED}"/${themesdir} || die
|
||||
rm Freeamp/Makefile{,.*} || die
|
||||
ln -s classic default_theme || die
|
||||
}
|
||||
54
x11-plugins/asclock/files/asclock-2.0.12-fix_gcc15.patch
Normal file
54
x11-plugins/asclock/files/asclock-2.0.12-fix_gcc15.patch
Normal file
@@ -0,0 +1,54 @@
|
||||
fix unprototyped functions
|
||||
https://build.opensuse.org/projects/openSUSE:Factory/packages/asclock/files/asclock-gcc15.patch
|
||||
--- a/asclock.h 2025-05-06 06:26:49.442371383 +0000
|
||||
+++ b/asclock.h 2025-05-06 06:32:27.594886122 +0000
|
||||
@@ -151,9 +151,9 @@ void parseArgs(int argc, char **argv);
|
||||
int read_init(FILE *f);
|
||||
int read_type(int *type);
|
||||
int read_token(char *str, int max);
|
||||
-int read_assign();
|
||||
+int read_assign(void);
|
||||
int read_int(int *ret);
|
||||
-int read_semicolon();
|
||||
+int read_semicolon(void);
|
||||
|
||||
#endif /* ASCLOCK_H */
|
||||
|
||||
--- a/config.c 2025-05-06 06:26:49.442272713 +0000
|
||||
+++ b/config.c 2025-05-06 06:33:07.998999146 +0000
|
||||
@@ -147,13 +147,13 @@ int loadTheme(char *themesdir)
|
||||
exit(-1);
|
||||
}
|
||||
|
||||
- if(!read_assign(f))
|
||||
+ if(!read_assign())
|
||||
printf("read_assign failed\n");
|
||||
|
||||
if(!read_int(s->addr))
|
||||
printf("read_int failed\n");
|
||||
|
||||
- if(!read_semicolon(f))
|
||||
+ if(!read_semicolon())
|
||||
printf("read_semicolon failed\n");
|
||||
}
|
||||
|
||||
--- a/parser.c 2025-05-06 06:26:49.442342036 +0000
|
||||
+++ b/parser.c 2025-05-06 06:32:42.238851768 +0000
|
||||
@@ -72,7 +72,7 @@ int read_token(char *str, int max)
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
-int read_assign()
|
||||
+int read_assign(void)
|
||||
{
|
||||
|
||||
while(next!='=')
|
||||
@@ -106,7 +106,7 @@ int read_int(int *ret)
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
-int read_semicolon()
|
||||
+int read_semicolon(void)
|
||||
{
|
||||
|
||||
while(next!=';')
|
||||
Reference in New Issue
Block a user