summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'games-fps/wolfgl/files/0.93-gcc4.patch')
-rw-r--r--games-fps/wolfgl/files/0.93-gcc4.patch80
1 files changed, 80 insertions, 0 deletions
diff --git a/games-fps/wolfgl/files/0.93-gcc4.patch b/games-fps/wolfgl/files/0.93-gcc4.patch
new file mode 100644
index 000000000000..5dcccd76049b
--- /dev/null
+++ b/games-fps/wolfgl/files/0.93-gcc4.patch
@@ -0,0 +1,80 @@
+diff -ur wolfgl-0.93-orig/common/id_ca.c wolfgl-0.93/common/id_ca.c
+--- wolfgl-0.93-orig/common/id_ca.c 2006-01-28 16:59:10.000000000 -0500
++++ wolfgl-0.93/common/id_ca.c 2006-01-28 17:04:26.000000000 -0500
+@@ -252,6 +252,7 @@
+ {
+ unsigned short ch,chhigh,count,offset;
+ unsigned short *copyptr, *inptr, *outptr;
++ unsigned char *uc_inptr;
+
+ length/=2;
+
+@@ -268,13 +269,17 @@
+ if (!count)
+ {
+ // have to insert a word containing the tag byte
+- ch |= *((unsigned char*)inptr)++;
++ uc_inptr = (unsigned char*)inptr;
++ ch |= *(uc_inptr)++;
++ inptr = (unsigned short *)uc_inptr;
+ *outptr++ = ch;
+ length--;
+ }
+ else
+ {
+- offset = *((unsigned char*)inptr)++;
++ uc_inptr = (unsigned char*)inptr;
++ offset = *(uc_inptr)++;
++ inptr = (unsigned short *)uc_inptr;
+ copyptr = outptr - offset;
+ length -= count;
+ while (count--)
+@@ -287,7 +292,9 @@
+ if (!count)
+ {
+ // have to insert a word containing the tag byte
+- ch |= *((unsigned char*)inptr)++;
++ uc_inptr = (unsigned char*)inptr;
++ ch |= *(uc_inptr)++;
++ inptr = (unsigned short *)uc_inptr;
+ *outptr++ = ch;
+ length --;
+ }
+@@ -806,7 +813,7 @@
+
+ for (i=0;i<NUMCHUNKS;i++)
+ if (grsegs[i])
+- MM_SetPurge (&(memptr)grsegs[i],3);
++ MM_SetPurge ((memptr)&grsegs[i],3);
+ ca_levelbit<<=1;
+ ca_levelnum++;
+ }
+@@ -862,7 +869,7 @@
+
+ for (i = 0; i < NUMCHUNKS; i++)
+ if (grsegs[i])
+- MM_SetPurge (&(memptr)grsegs[i],3);
++ MM_SetPurge ((memptr)&grsegs[i],3);
+ }
+
+ //===========================================================================
+diff -ur wolfgl-0.93-orig/common/wl_game.c wolfgl-0.93/common/wl_game.c
+--- wolfgl-0.93-orig/common/wl_game.c 2006-01-28 16:59:10.000000000 -0500
++++ wolfgl-0.93/common/wl_game.c 2006-01-28 17:07:08.000000000 -0500
+@@ -545,13 +545,13 @@
+ {
+ // solid wall
+ tilemap[x][y] = tile;
+- (unsigned short)actorat[x][y] = tile;
++ actorat[x][y] = tile;
+ }
+ else
+ {
+ // area floor
+ tilemap[x][y] = 0;
+- (unsigned short)actorat[x][y] = 0;
++ actorat[x][y] = 0;
+ }
+ }
+
+