games/sdlroids: fix build with -fno-common

Turn a variable definition in a header file into a declaration.
This fixes the build on FreeBSD 13+.
This commit is contained in:
Robert Clausecker 2023-04-13 15:45:28 +02:00
parent e19be2d61b
commit c2358eae97
2 changed files with 10 additions and 5 deletions

View file

@ -1,6 +1,6 @@
PORTNAME= sdlroids PORTNAME= sdlroids
PORTVERSION= 1.3.4 DISTVERSION= 1.3.4
PORTREVISION= 18 PORTREVISION= 19
CATEGORIES= games CATEGORIES= games
MASTER_SITES= SF \ MASTER_SITES= SF \
SF/nemysisfreebsdp/${CATEGORIES}/:icons SF/nemysisfreebsdp/${CATEGORIES}/:icons
@ -16,9 +16,6 @@ WWW= https://sourceforge.net/projects/sdlroids/
LICENSE= GPLv2 LICENSE= GPLv2
LICENSE_FILE= ${WRKSRC}/COPYING LICENSE_FILE= ${WRKSRC}/COPYING
BROKEN_FreeBSD_13= ld: error: duplicate symbol: flagargs
BROKEN_FreeBSD_14= ld: error: duplicate symbol: flagargs
USES= gmake sdl tar:bzip2 USES= gmake sdl tar:bzip2
GNU_CONFIGURE= yes GNU_CONFIGURE= yes
CONFIGURE_ARGS= --datadir=${PREFIX}/share CONFIGURE_ARGS= --datadir=${PREFIX}/share

View file

@ -0,0 +1,8 @@
--- getargs.h.orig 2023-04-13 13:43:47 UTC
+++ getargs.h
@@ -37,4 +37,4 @@
/* getargs() prototype */
void getargs(int, char *[]);
-int flagargs[NUMARGS];
+extern int flagargs[NUMARGS];