diff options
author | fjoe <fjoe@FreeBSD.org> | 2007-11-15 08:33:17 +0000 |
---|---|---|
committer | fjoe <fjoe@FreeBSD.org> | 2007-11-15 08:33:17 +0000 |
commit | a9fccf186da8253c209bce327fdb35322806d9ec (patch) | |
tree | ce081a5796a950a995f16a665deb4f9c2297d931 | |
parent | 6f946385e1c7f4067e4437036365a754197d2e32 (diff) | |
download | FreeBSD-ports-a9fccf186da8253c209bce327fdb35322806d9ec.zip FreeBSD-ports-a9fccf186da8253c209bce327fdb35322806d9ec.tar.gz |
Fix gcc 4.2 build.
Approved by: portmgr (pav), MAINTAINER (danfe)
-rw-r--r-- | games/fuhquake/Makefile | 4 | ||||
-rw-r--r-- | games/fuhquake/files/patch-cl_main.c | 13 | ||||
-rw-r--r-- | games/fuhquake/files/patch-gl_texture.c | 11 | ||||
-rw-r--r-- | games/fuhquake/files/patch-snd_dma.c | 19 |
4 files changed, 41 insertions, 6 deletions
diff --git a/games/fuhquake/Makefile b/games/fuhquake/Makefile index dd4cd79..461eca7 100644 --- a/games/fuhquake/Makefile +++ b/games/fuhquake/Makefile @@ -39,10 +39,6 @@ MAKE_ENV= DATADIR="${DATADIR}" .include <bsd.port.pre.mk> -.if ${OSVERSION} >= 700042 -BROKEN= Does not compile with GCC 4.2 -.endif - .if !defined(WITH_GLX) && !defined(WITH_X11) IGNORE= needs at least one client (GLX or X11) .endif diff --git a/games/fuhquake/files/patch-cl_main.c b/games/fuhquake/files/patch-cl_main.c index cd7a506..0452509 100644 --- a/games/fuhquake/files/patch-cl_main.c +++ b/games/fuhquake/files/patch-cl_main.c @@ -1,5 +1,5 @@ ---- cl_main.c.orig Wed Jan 7 00:39:44 2004 -+++ cl_main.c Sun Jan 22 22:49:30 2006 +--- cl_main.c.orig 2004-01-07 00:39:44.000000000 +0600 ++++ cl_main.c 2007-11-15 00:01:57.000000000 +0600 @@ -44,6 +44,10 @@ #include "mp3_player.h" @@ -11,6 +11,15 @@ #include <netdb.h> #endif +@@ -380,7 +384,7 @@ + Q_strncpyz(address, Cmd_Argv(1), sizeof(address)); + if (s = strchr(address, ':')) + *s = 0; +- if (((int) addr.s_addr = inet_addr(address)) == INADDR_NONE) { ++ if ((addr.s_addr = inet_addr(address)) == INADDR_NONE) { + //forward lookup + if (!(h = gethostbyname(address))) { + Com_Printf("Couldn't resolve %s\n", address); @@ -850,19 +854,16 @@ Sys_Error ("Couldn't load gfx/colormap.lmp"); FMod_CheckModel("gfx/colormap.lmp", host_colormap, com_filesize); diff --git a/games/fuhquake/files/patch-gl_texture.c b/games/fuhquake/files/patch-gl_texture.c new file mode 100644 index 0000000..415b500 --- /dev/null +++ b/games/fuhquake/files/patch-gl_texture.c @@ -0,0 +1,11 @@ +--- gl_texture.c.orig 2007-11-15 00:10:30.000000000 +0600 ++++ gl_texture.c 2007-11-15 00:10:38.000000000 +0600 +@@ -159,7 +159,7 @@ + } + + static GLenum oldtarget = GL_TEXTURE0_ARB; +-static int cnttextures[4] = {-1, -1, -1, -1}; ++int cnttextures[4] = {-1, -1, -1, -1}; + static qboolean mtexenabled = false; + + diff --git a/games/fuhquake/files/patch-snd_dma.c b/games/fuhquake/files/patch-snd_dma.c new file mode 100644 index 0000000..193caf6 --- /dev/null +++ b/games/fuhquake/files/patch-snd_dma.c @@ -0,0 +1,19 @@ +--- snd_dma.c.orig 2007-11-14 23:38:25.000000000 +0600 ++++ snd_dma.c 2007-11-14 23:41:15.000000000 +0600 +@@ -49,11 +49,11 @@ + volatile dma_t *shm = 0; + volatile dma_t sn; + +-static vec3_t listener_origin; +-static vec3_t listener_forward; +-static vec3_t listener_right; +-static vec3_t listener_up; +-static vec_t sound_nominal_clip_dist = 1000.0; ++vec3_t listener_origin; ++vec3_t listener_forward; ++vec3_t listener_right; ++vec3_t listener_up; ++vec_t sound_nominal_clip_dist = 1000.0; + + static int soundtime; // sample PAIRS + int paintedtime; // sample PAIRS |