Saturday, January 30, 2021

games/xblast: fix with -fno-common

I took this from FreeBSD [0]. It builds and works fine on amd64.

OK?

Charlène.


[0] https://github.com/freebsd/freebsd-ports/commit/52377c76

Index: Makefile
===================================================================
RCS file: /cvs/ports/games/xblast/Makefile,v
retrieving revision 1.30
diff -u -p -u -p -r1.30 Makefile
--- Makefile 12 Jul 2019 20:46:26 -0000 1.30
+++ Makefile 30 Jan 2021 16:56:00 -0000
@@ -3,7 +3,7 @@
COMMENT= graphical multi-player real-time strategy game for X11

DISTNAME= xblast-2.10.4
-REVISION= 3
+REVISION= 4
DIST_SUBDIR= xblast
DISTFILES= ${DISTNAME}${EXTRACT_SUFX} \
images-2005-01-06${EXTRACT_SUFX} \
Index: patches/patch-cfg_control_h
===================================================================
RCS file: patches/patch-cfg_control_h
diff -N patches/patch-cfg_control_h
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-cfg_control_h 30 Jan 2021 16:56:00 -0000
@@ -0,0 +1,16 @@
+$OpenBSD$
+
+Fix -fno-common build failure.
+
+Index: cfg_control.h
+--- cfg_control.h.orig
++++ cfg_control.h
+@@ -29,7 +29,7 @@
+ #define NUM_KEYB_CONTROLS 2
+
+ /* constant assignment of control to event type */
+-const XBEventCode keyEventType[NUM_KEYB_CONTROLS];
++extern const XBEventCode keyEventType[NUM_KEYB_CONTROLS];
+
+ /* ingame controls for editing*/
+ typedef struct
Index: patches/patch-network_h
===================================================================
RCS file: patches/patch-network_h
diff -N patches/patch-network_h
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ patches/patch-network_h 30 Jan 2021 16:56:00 -0000
@@ -0,0 +1,16 @@
+$OpenBSD$
+
+Fix -fno-common build failure.
+
+Index: network.h
+--- network.h.orig
++++ network.h
+@@ -105,7 +105,7 @@ typedef enum
+ #define TEAM_UNDEF 252
+
+ /* team color assignment */
+-const XBColor teamColors[NUM_XBTS];
++extern const XBColor teamColors[NUM_XBTS];
+
+ /* results of game config receive/create */
+ typedef enum

No comments:

Post a Comment