Skip to content

Commit

Permalink
games/sdlroids: fix build with -fno-common
Browse files Browse the repository at this point in the history
Turn a variable definition in a header file into a declaration.
This fixes the build on FreeBSD 13+.
  • Loading branch information
clausecker committed Apr 14, 2023
1 parent e19be2d commit c2358ea
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
7 changes: 2 additions & 5 deletions games/sdlroids/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PORTNAME= sdlroids
PORTVERSION= 1.3.4
PORTREVISION= 18
DISTVERSION= 1.3.4
PORTREVISION= 19
CATEGORIES= games
MASTER_SITES= SF \
SF/nemysisfreebsdp/${CATEGORIES}/:icons
Expand All @@ -16,9 +16,6 @@ WWW= https://sourceforge.net/projects/sdlroids/
LICENSE= GPLv2
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
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --datadir=${PREFIX}/share
Expand Down
8 changes: 8 additions & 0 deletions games/sdlroids/files/patch-getargs.h
Original file line number Diff line number Diff line change
@@ -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];

0 comments on commit c2358ea

Please sign in to comment.