Merge branch 'gcc10-fixes' into 'master'

GCC 10 compiling fixes

See merge request STJr/SRB2!937
This commit is contained in:
Monster Iestyn 2020-05-12 14:47:49 -04:00
commit 0f4ada3d12
6 changed files with 16 additions and 9 deletions

View File

@ -125,6 +125,8 @@ boolean advancedemo;
INT32 debugload = 0;
#endif
char savegamename[256];
char srb2home[256] = ".";
char srb2path[256] = ".";
boolean usehome = true;

View File

@ -458,7 +458,7 @@ void CONS_Debug(INT32 debugflags, const char *fmt, ...) FUNCDEBUG;
// Things that used to be in dstrings.h
#define SAVEGAMENAME "srb2sav"
char savegamename[256];
extern char savegamename[256];
// m_misc.h
#ifdef GETTEXT

View File

@ -545,7 +545,7 @@ extern recorddata_t *mainrecords[NUMMAPS];
extern UINT8 mapvisited[NUMMAPS];
// Temporary holding place for nights data for the current map
nightsdata_t ntemprecords;
extern nightsdata_t ntemprecords;
extern UINT32 token; ///< Number of tokens collected in a level
extern UINT32 tokenlist; ///< List of tokens collected

View File

@ -68,7 +68,7 @@ extern consvar_t cv_masterserver, cv_servername;
// < 0 to not connect (usually -1) (offline mode)
// == 0 to show all rooms, not a valid hosting room
// anything else is whatever room the MS assigns to that number (online mode)
INT16 ms_RoomId;
extern INT16 ms_RoomId;
const char *GetMasterServerPort(void);
const char *GetMasterServerIP(void);

View File

@ -134,6 +134,7 @@ consvar_t cv_playmusicifunfocused = {"playmusicifunfocused", "No", CV_SAVE, CV_Y
consvar_t cv_playsoundsifunfocused = {"playsoundsifunfocused", "No", CV_SAVE, CV_YesNo, NULL, 0, NULL, NULL, 0, 0, NULL};
#ifdef HAVE_OPENMPT
openmpt_module *openmpt_mhandle = NULL;
static CV_PossibleValue_t interpolationfilter_cons_t[] = {{0, "Default"}, {1, "None"}, {2, "Linear"}, {4, "Cubic"}, {8, "Windowed sinc"}, {0, NULL}};
consvar_t cv_modfilter = {"modfilter", "0", CV_SAVE|CV_CALL, interpolationfilter_cons_t, ModFilter_OnChange, 0, NULL, NULL, 0, 0, NULL};
#endif
@ -1910,6 +1911,10 @@ UINT32 S_GetMusicPosition(void)
/// In this section: mazmazz doesn't know how to do dynamic arrays or struct pointers!
/// ------------------------
char music_stack_nextmusname[7];
boolean music_stack_noposition = false;
UINT32 music_stack_fadeout = 0;
UINT32 music_stack_fadein = 0;
static musicstack_t *music_stacks = NULL;
static musicstack_t *last_music_stack = NULL;

View File

@ -22,7 +22,7 @@
#ifdef HAVE_OPENMPT
#include "libopenmpt/libopenmpt.h"
openmpt_module *openmpt_mhandle;
extern openmpt_module *openmpt_mhandle;
#endif
// mask used to indicate sound origin is player item pickup
@ -262,10 +262,10 @@ typedef struct musicstack_s
struct musicstack_s *next;
} musicstack_t;
char music_stack_nextmusname[7];
boolean music_stack_noposition;
UINT32 music_stack_fadeout;
UINT32 music_stack_fadein;
extern char music_stack_nextmusname[7];
extern boolean music_stack_noposition;
extern UINT32 music_stack_fadeout;
extern UINT32 music_stack_fadein;
void S_SetStackAdjustmentStart(void);
void S_AdjustMusicStackTics(void);
@ -333,7 +333,7 @@ void S_StopSoundByNum(sfxenum_t sfxnum);
#ifdef MUSICSLOT_COMPATIBILITY
// For compatibility with code/scripts relying on older versions
// This is a list of all the "special" slot names and their associated numbers
const char *compat_special_music_slots[16];
extern const char *compat_special_music_slots[16];
#endif
#endif