Control: tags -1 + patch

Hi,

the attached patch fixes the FTBFS with GCC 10.

Regards,
  Reiner
diff -u xgammon-0.99.1128/src/xgammon.c xgammon-0.99.1128/src/xgammon.c
--- xgammon-0.99.1128/src/xgammon.c
+++ xgammon-0.99.1128/src/xgammon.c
@@ -150,6 +150,14 @@
 #endif
 
 
+struct _PinTable Pin[29], rollout_position[29];	/* 0, 25 = bar, 1 - 24 = board and 26, 27 finished[color] */
+struct _RolloutSave rollout_save;
+MOVE possible_moves[8000], *list;
+FILE *endgame_database;
+struct _Player Player[2];
+struct _Tournament tournament;
+struct _gammon_resource gammon_resource;
+
 
 XtAppContext	app_con;
 
only in patch2:
unchanged:
--- xgammon-0.99.1128.orig/src/gammon.h
+++ xgammon-0.99.1128/src/gammon.h
@@ -117,12 +117,16 @@
 	MoveFunc MoveFunction;
 	BOARD board;
 	X11SET X11Set;
-} Player[2];
+};
+
+extern struct _Player Player[2];
 
 struct  _PinTable {
         int count;
         int color;
-} Pin[29], rollout_position[29];	/* 0, 25 = bar, 1 - 24 = board and 26, 27 finished[color] */
+};
+
+extern struct _PinTable Pin[29], rollout_position[29];	/* 0, 25 = bar, 1 - 24 = board and 26, 27 finished[color] */
 
 
 /* if you have the dice values 1 and 1 and all stones are on different
@@ -137,7 +141,7 @@
         int to;
 } MOVE;
 
-MOVE possible_moves[8000], *list;
+extern MOVE possible_moves[8000], *list;
 
 struct _move_hist {
 	int	    from [4];
@@ -151,16 +155,20 @@
 struct _Tournament {
 	unsigned int   game_number;
 	unsigned int   winning_point;
-} tournament;
+};
+
+extern struct _Tournament tournament;
 
 struct _RolloutSave {
 	int turn;
 	int doubler_value;
 	int doubler_owner;
 	int roll[2];
-} rollout_save;
+};
+
+extern struct _RolloutSave rollout_save;
 
-FILE *endgame_database;
+extern FILE *endgame_database;
 
 extern void switch_turn();
 
only in patch2:
unchanged:
--- xgammon-0.99.1128.orig/src/xgammon.h
+++ xgammon-0.99.1128/src/xgammon.h
@@ -70,7 +70,9 @@
 	char	*server;
 	int     port;
 	int     button_move;
-} gammon_resource;
+};
+
+extern struct _gammon_resource gammon_resource;
 
 /* diawin.c */
 extern void AppendDialogText ();

Attachment: signature.asc
Description: PGP signature

Reply via email to