From 0d57ba1d02c5bde2ab22a71d21a95849b21e9539 Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 24 Aug 2020 17:51:01 -0700 Subject: [PATCH 1/6] Fix NOGME compiling --- src/sdl/mixer_sound.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/sdl/mixer_sound.c b/src/sdl/mixer_sound.c index 86fc8efb..c5650192 100644 --- a/src/sdl/mixer_sound.c +++ b/src/sdl/mixer_sound.c @@ -110,6 +110,7 @@ static void var_cleanup(void) internal_volume = 100; } +#if defined (HAVE_LIBGME) && defined (HAVE_ZLIB) static const char* get_zlib_error(int zErr) { switch (zErr) @@ -130,6 +131,7 @@ static const char* get_zlib_error(int zErr) return "unknown error"; } } +#endif /// ------------------------ /// Audio System From fbde926497d5c6da5872525214f501dfb450a1cd Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 24 Aug 2020 17:52:55 -0700 Subject: [PATCH 2/6] Fix NOPNG compiling --- src/w_wad.c | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/src/w_wad.c b/src/w_wad.c index 77d0d6d2..d4da027b 100644 --- a/src/w_wad.c +++ b/src/w_wad.c @@ -11,6 +11,24 @@ /// \file w_wad.c /// \brief Handles WAD file header, directory, lump I/O +#ifdef HAVE_ZLIB +#ifndef _MSC_VER +#ifndef _LARGEFILE64_SOURCE +#define _LARGEFILE64_SOURCE +#endif +#endif + +#ifndef _LFS64_LARGEFILE +#define _LFS64_LARGEFILE +#endif + +#ifndef _FILE_OFFSET_BITS +#define _FILE_OFFSET_BITS 0 +#endif + +#include "zlib.h" +#endif + #ifdef __GNUC__ #include #endif @@ -66,24 +84,6 @@ int snprintf(char *str, size_t n, const char *fmt, ...); #define O_BINARY 0 #endif -#ifdef HAVE_ZLIB -#ifndef _MSC_VER -#ifndef _LARGEFILE64_SOURCE -#define _LARGEFILE64_SOURCE -#endif -#endif - -#ifndef _LFS64_LARGEFILE -#define _LFS64_LARGEFILE -#endif - -#ifndef _FILE_OFFSET_BITS -#define _FILE_OFFSET_BITS 0 -#endif - -#include "zlib.h" -#endif - typedef struct { From 16fc87edcf2be81c4ae0d1bdeb337e3a38a785f8 Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 24 Aug 2020 17:55:42 -0700 Subject: [PATCH 3/6] Fix NOMIXER compiling --- src/sdl/sdl_sound.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/sdl/sdl_sound.c b/src/sdl/sdl_sound.c index 4bb1b567..929ac79f 100644 --- a/src/sdl/sdl_sound.c +++ b/src/sdl/sdl_sound.c @@ -1434,6 +1434,8 @@ static void I_ResumeGME(void) boolean I_LoadSong(char *data, size_t len) { + (void)data; + (void)len; return false; } @@ -1495,6 +1497,7 @@ boolean I_FadeSongFromVolume(UINT8 target_volume, UINT8 source_volume, UINT32 ms (void)target_volume; (void)source_volume; (void)ms; + (void)callback; return false; } @@ -1502,6 +1505,7 @@ boolean I_FadeSong(UINT8 target_volume, UINT32 ms, void (*callback)(void)) { (void)target_volume; (void)ms; + (void)callback; return false; } From 3437b0690a3f4278e3ecc657102a126a3e2f3d13 Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 24 Aug 2020 17:58:39 -0700 Subject: [PATCH 4/6] Kill NOHS --- src/Makefile | 24 ------------------------ src/doomdef.h | 6 ------ src/sdl/Makefile.cfg | 22 ---------------------- 3 files changed, 52 deletions(-) diff --git a/src/Makefile b/src/Makefile index dd678cb2..b417a38e 100644 --- a/src/Makefile +++ b/src/Makefile @@ -63,7 +63,6 @@ # Compile with extra warnings, add 'WARNINGMODE=1' # Compile without NASM's tmap.nas, add 'NOASM=1' # Compile without 3D hardware support, add 'NOHW=1' -# Compile without 3D sound support, add 'NOHS=1' # Compile with GDBstubs, add 'RDB=1' # Compile without PNG, add 'NOPNG=1' # Compile without zlib, add 'NOZLIB=1' @@ -136,7 +135,6 @@ NOPNG=1 NOZLIB=1 NONET=1 NOHW=1 -NOHS=1 NOASM=1 NOIPX=1 EXENAME?=srb2dummy @@ -167,7 +165,6 @@ endif ifdef PANDORA NONX86=1 NOHW=1 -NOHS=1 endif ifdef WII @@ -217,7 +214,6 @@ NOPNG=1 NOZLIB=1 NONET=1 #NOHW=1 -NOHS=1 NOASM=1 NOIPX=1 NONX86=1 @@ -287,13 +283,6 @@ endif $(OBJDIR)/hw_md2load.o $(OBJDIR)/hw_md3load.o $(OBJDIR)/hw_model.o $(OBJDIR)/u_list.o endif -ifdef NOHS - OPTS+=-DNOHS -else - OPTS+=-DHW3SOUND - OBJS+=$(OBJDIR)/hw3sound.o -endif - OPTS += -DCOMPVERSION ifndef NONX86 @@ -942,19 +931,6 @@ $(OBJDIR)/r_minigl.o: hardware/r_minigl/r_minigl.c hardware/r_opengl/r_opengl.h $(CC) $(CFLAGS) $(WFLAGS) -D_WINDOWS -mwindows -c $< -o $@ endif -ifndef NOHS -$(OBJDIR)/s_ds3d.o: hardware/s_ds3d/s_ds3d.c hardware/hw3dsdrv.h \ - hardware/hw_dll.h - $(CC) $(ARCHOPTS) -Os -o $(OBJDIR)/s_ds3d.o $(WFLAGS) -D_WINDOWS -mwindows -c hardware/s_ds3d/s_ds3d.c - -$(OBJDIR)/s_fmod.o: hardware/s_openal/s_openal.c hardware/hw3dsdrv.h \ - hardware/hw_dll.h - $(CC) $(ARCHOPTS) -Os -o $(OBJDIR)/s_fmod.o $(WFLAGS) -D_WINDOWS -mwindows -c hardware/s_fmod/s_fmod.c - -$(OBJDIR)/s_openal.o: hardware/s_openal/s_openal.c hardware/hw3dsdrv.h \ - hardware/hw_dll.h - $(CC) $(ARCHOPTS) -Os -o $(OBJDIR)/s_openal.o $(WFLAGS) -D_WINDOWS -mwindows -c hardware/s_openal/s_openal.c -endif endif endif diff --git a/src/doomdef.h b/src/doomdef.h index 1965b3d0..be4557b1 100644 --- a/src/doomdef.h +++ b/src/doomdef.h @@ -30,7 +30,6 @@ #ifdef HAVE_MIXER //#if !defined(DC) && !defined(_WIN32_WCE) && !defined(_XBOX) && !defined(GP2X) #define SOUND SOUND_MIXER - #define NOHS // No HW3SOUND #ifdef HW3SOUND #undef HW3SOUND #endif @@ -47,7 +46,6 @@ // Use FMOD? #ifdef HAVE_FMOD #define SOUND SOUND_FMOD - #define NOHS // No HW3SOUND #ifdef HW3SOUND #undef HW3SOUND #endif @@ -64,10 +62,6 @@ #if !defined (HWRENDER) && !defined (NOHW) #define HWRENDER #endif -// judgecutor: 3D sound support -#if !defined(HW3SOUND) && !defined (NOHS) -#define HW3SOUND -#endif #endif #if defined (_WIN32) || defined (_WIN32_WCE) diff --git a/src/sdl/Makefile.cfg b/src/sdl/Makefile.cfg index b0c591ce..1744d691 100644 --- a/src/sdl/Makefile.cfg +++ b/src/sdl/Makefile.cfg @@ -53,28 +53,6 @@ ifndef NOHW OBJS+=$(OBJDIR)/r_opengl.o $(OBJDIR)/ogl_sdl.o endif -ifndef NOHS -ifdef OPENAL - OBJS+=$(OBJDIR)/s_openal.o - OPTS+=-DSTATIC3DS - STATICHS=1 -else -ifdef FMOD - OBJS+=$(OBJDIR)/s_fmod.o - OPTS+=-DSTATIC3DS - STATICHS=1 -else -ifdef MINGW -ifdef DS3D - OBJS+=$(OBJDIR)/s_ds3d.o - OPTS+=-DSTATIC3DS - STATICHS=1 -endif -endif -endif -endif -endif - ifdef NOMIXER i_sound_o=$(OBJDIR)/sdl_sound.o else From 04d774c76515a76f548c58929502484d02bfd2fc Mon Sep 17 00:00:00 2001 From: James R Date: Mon, 24 Aug 2020 18:06:00 -0700 Subject: [PATCH 5/6] Fix NOHW compiling --- src/p_setup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/p_setup.c b/src/p_setup.c index f9e23a5e..301ba384 100644 --- a/src/p_setup.c +++ b/src/p_setup.c @@ -1401,8 +1401,6 @@ static void P_LoadRawSideDefs2(void *data) { UINT16 i; INT32 num; - size_t j; - RGBA_t color; for (i = 0; i < numsides; i++) { @@ -1469,6 +1467,8 @@ static void P_LoadRawSideDefs2(void *data) || (msd->bottomtexture[0] == '#' && msd->bottomtexture[1] && msd->bottomtexture[2] && msd->bottomtexture[3] && msd->bottomtexture[4] && msd->bottomtexture[5] && msd->bottomtexture[6])) { char *col; + RGBA_t color; + size_t j; sec->midmap = R_CreateColormap(msd->toptexture, msd->midtexture, msd->bottomtexture); From 27b72ccbf57943fe7fde39277c3056e2a39e281e Mon Sep 17 00:00:00 2001 From: ThatAwesomeGuy173 Date: Tue, 25 Aug 2020 23:12:31 -0600 Subject: [PATCH 6/6] Replace 'ignoring skin' debug print with a proper console warning --- src/r_things.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/r_things.c b/src/r_things.c index 25c4edb3..9cb35e19 100644 --- a/src/r_things.c +++ b/src/r_things.c @@ -2746,7 +2746,7 @@ void R_AddSkins(UINT16 wadnum) if (numskins >= MAXSKINS) { - CONS_Debug(DBG_RENDER, "ignored skin (%d skins maximum)\n", MAXSKINS); + CONS_Alert(CONS_WARNING, M_GetText("Unable to add skin, too many characters are loaded (%d maximum)\n"), MAXSKINS); continue; // so we know how many skins couldn't be added } buf = W_CacheLumpNumPwad(wadnum, lump, PU_CACHE);