Fix some build errors

This commit is contained in:
Steel Titanium 2020-04-07 19:07:39 -04:00
parent 6fcc06bf72
commit cb9004e4cf
3 changed files with 8 additions and 2 deletions

View File

@ -36,7 +36,7 @@ jobs:
- v1-SRB2-APT
- run:
name: Install SDK
command: apt-get -qq -y --no-install-recommends install git build-essential nasm libpng-dev:i386 libsdl2-mixer-dev:i386 libgme-dev:i386 gettext ccache wget gcc-multilib upx openssh-client
command: apt-get -qq -y --no-install-recommends install git build-essential nasm libpng-dev:i386 libsdl2-mixer-dev:i386 libgme-dev:i386 libcurl4-openssl-dev:i386 gettext ccache wget gcc-multilib upx openssh-client
- save_cache:
key: v1-SRB2-APT
paths:

View File

@ -220,7 +220,7 @@ set(SRB2_CONFIG_HAVE_ZLIB ON CACHE BOOL
"Enable zlib support.")
set(SRB2_CONFIG_HAVE_GME ON CACHE BOOL
"Enable GME support.")
set(SRB2_CONFIG_HAVE_GME ON CACHE BOOL
set(SRB2_CONFIG_HAVE_CURL ON CACHE BOOL
"Enable curl support, used for downloading files via HTTP.")
set(SRB2_CONFIG_HWRENDER ON CACHE BOOL
"Enable hardware rendering through OpenGL.")

View File

@ -1255,7 +1255,9 @@ static inline void CL_DrawConnectionStatus(void)
break;
case CL_ASKDOWNLOADFILES:
case CL_WAITDOWNLOADFILESRESPONSE:
#ifdef HAVE_CURL
case CL_PREPAREHTTPFILES:
#endif
cltext = M_GetText("Waiting to download files...");
default:
cltext = M_GetText("Connecting to server...");
@ -1385,7 +1387,9 @@ static void SV_SendServerInfo(INT32 node, tic_t servertime)
netbuffer->u.serverinfo.iszone = 0;
memset(netbuffer->u.serverinfo.maptitle, 0, 33);
#ifdef HAVE_CURL
memset(netbuffer->u.serverinfo.httpsource, 0, MAX_MIRROR_LENGTH);
#endif
if (!(mapheaderinfo[gamemap-1]->menuflags & LF2_HIDEINMENU) && mapheaderinfo[gamemap-1]->lvlttl[0])
{
@ -1437,6 +1441,7 @@ static void SV_SendServerInfo(INT32 node, tic_t servertime)
netbuffer->u.serverinfo.actnum = 0; //mapheaderinfo[gamemap-1]->actnum
#ifdef HAVE_CURL
mirror_length = strlen(cv_httpsource.string);
if (mirror_length > MAX_MIRROR_LENGTH)
mirror_length = MAX_MIRROR_LENGTH;
@ -1446,6 +1451,7 @@ static void SV_SendServerInfo(INT32 node, tic_t servertime)
strncpy(netbuffer->u.serverinfo.httpsource, "", MAX_MIRROR_LENGTH);
netbuffer->u.serverinfo.httpsource[MAX_MIRROR_LENGTH-1] = 0;
#endif
p = PutFileNeeded(0);