aboutsummaryrefslogtreecommitdiff
path: root/games/tecnoballz/files/patch-64bit
diff options
context:
space:
mode:
Diffstat (limited to 'games/tecnoballz/files/patch-64bit')
-rw-r--r--games/tecnoballz/files/patch-64bit144
1 files changed, 144 insertions, 0 deletions
diff --git a/games/tecnoballz/files/patch-64bit b/games/tecnoballz/files/patch-64bit
new file mode 100644
index 000000000000..80f8ce93856a
--- /dev/null
+++ b/games/tecnoballz/files/patch-64bit
@@ -0,0 +1,144 @@
+These changes are mostly (though not enirely) cosmetic --
+they ensure warning-free compilation on 64-bit platforms.
+
+ -mi
+
+--- src/audiomixer.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/audiomixer.cc 2007-07-27 01:38:09.000000000 -0400
+@@ -350,5 +350,5 @@
+ return (erreur_num = E_SDLMIXER);
+ }
+- Sint32 *p = (Sint32 *)pMixmodule;
++ intptr_t *p = (intptr_t *)pMixmodule;
+ ptModAmiga = (MODULE *)p[1];
+
+--- src/fond_ecran.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/fond_ecran.cc 2007-07-27 01:39:22.000000000 -0400
+@@ -134,6 +134,6 @@
+ //###############################################################
+ Sint32 src_X = 0;
+- Sint32 h = (Sint32)ecran; //use pointer address as random value
+- Sint32 k = (Sint32)fonds; //use pointer address as random value
++ Sint32 h = (intptr_t)ecran; //use pointer address as random value
++ Sint32 k = (intptr_t)fonds; //use pointer address as random value
+ Sint32 nline;
+ if(mVert > 0)
+--- src/mentatCode.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/mentatCode.cc 2007-07-27 01:42:19.000000000 -0400
+@@ -86,5 +86,5 @@
+ if(is_verbose)
+ printf("mentatCode::first_init() [START]\n");
+- hasard_val = (Sint32)first_init;
++ hasard_val = (intptr_t)first_init;
+ memGestion = new RAM_killer();
+ memGestion->initialise(8000);
+@@ -337,14 +337,14 @@
+ delete ptScoreTab;
+ if(is_verbose)
+- printf("==7 ecran_gere %x\n", (Sint32)ecran_gere);
++ printf("==7 ecran_gere %p\n", ecran_gere);
+ delete ecran_gere;
+ #ifndef SOUNDISOFF
+ if(is_verbose)
+- printf("==8 audiomixer %x\n", (Sint32)ptAudiomix);
++ printf("==8 audiomixer %p\n", ptAudiomix);
+ delete ptAudiomix;
+ #endif
+ delete pRessource;
+ if(is_verbose)
+- printf("==9 memGestion %x \n", (Sint32)memGestion);
++ printf("==9 memGestion %p\n", memGestion);
+ delete memGestion;
+ return num_erreur;
+--- src/scrolledit.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/scrolledit.cc 2007-07-27 01:43:05.000000000 -0400
+@@ -657,5 +657,5 @@
+ table += (brush_posx / defilement->motiflarge);
+
+- printf("scrolledit::brush_draw() : (table - carteFirst):%i / i:%i\n",
++ printf("scrolledit::brush_draw() : (table - carteFirst):%ti / i:%i\n",
+ (table - defilement->carteFirst), i);
+
+--- src/tecno_boui.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/tecno_boui.cc 2007-07-27 01:44:19.000000000 -0400
+@@ -64,5 +64,5 @@
+ { flag_actif = 1;
+ Sint32 *monPT = ghost_bobs + (hasard_val & 31);
+- hasard_val += (Sint32)this;
++ hasard_val += (intptr_t)this;
+ Sint32 k = *monPT;
+ miniOffset = k;
+@@ -191,5 +191,5 @@
+ i &= 31;
+ atom_traje = i;
+- hasard_val += (Sint32)this;
++ hasard_val += (intptr_t)this;
+
+
+--- src/zeNewBalls.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/zeNewBalls.cc 2007-07-27 01:45:35.000000000 -0400
+@@ -629,6 +629,6 @@
+ //(char *)monPT += j;
+ monPT = (Sint32 *)((char *)monPT + j);
+- printf("monPT = %x / bumpX->rebonds_GD = %x / *monPT = %i\n",
+- (Sint32)monPT, (Sint32)bumpX->rebonds_GD, *monPT);
++ printf("monPT = %p / bumpX->rebonds_GD = %p / *monPT = %i\n",
++ monPT, bumpX->rebonds_GD, *monPT);
+
+ printf("%i %i\n", bumpX->rebonds_GD[16], bumpX->rebonds_GD[64]);
+--- src/ze_magneye.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/ze_magneye.cc 2007-07-27 01:46:11.000000000 -0400
+@@ -70,5 +70,5 @@
+ { techno_eye *ptEye = objetListe[i];
+ ptEye->centerPosx = Xcoordinat[hval & 31] * resolution;
+- hval += (Sint32)ptEye;
++ hval += (intptr_t)ptEye;
+ ptEye->centerPosy = Ycoordinat[hval & 31] * resolution;
+ hval += keyGestion->sourisGetY();
+--- src/RAM_killer.cc 2005-03-01 09:15:08.000000000 -0500
++++ src/RAM_killer.cc 2007-07-27 08:24:00.000000000 -0400
+@@ -78,8 +78,5 @@
+ {
+ place *= double_mem;
+- char *memPt = NULL;
+- char nulle = 0;
+- char *monPT;
+- Sint32 i ;
++ char *memPt;
+
+ if(mem_nombre == memMaximum)
+@@ -87,5 +84,5 @@
+ return 0;
+ }
+- memPt = (char *) malloc((Sint32)place);
++ memPt = (char *) calloc(place, 1);
+ if(!memPt)
+ { erreur_num = E_NOMEMORY; //allocate error
+@@ -102,7 +99,4 @@
+ if(mem_nombre > maxi_zones)
+ maxi_zones = mem_nombre;
+- monPT = memPt;
+- for(i = 0; i < place; i++)
+- *(monPT++) = nulle; //clear memory
+ //printf("RAM_killer::reserveMem(%i, %x)\n", place, ident);
+ return memPt;
+@@ -140,6 +134,6 @@
+ if(adres)
+ { adrNoFound++;
+- fprintf(stderr, "RAM_killer::liberation() : %i) address %x not found\n",
+- adrNoFound, (Sint32)adres);
++ fprintf(stderr, "RAM_killer::liberation() : %i) address %p not found\n",
++ adrNoFound, adres);
+ }
+ }
+@@ -156,7 +150,7 @@
+ if(adres)
+ { fprintf(stderr,
+- "RAM_killer::libereTout() : addr:%x; size:%i; id:%x\n",
+- (Sint32)memPT->adresseMem, memPT->taille_mem,
+- (Sint32)memPT->identifier);
++ "RAM_killer::libereTout() : addr:%p; size:%i; id:%p\n",
++ memPT->adresseMem, memPT->taille_mem,
++ memPT->identifier);
+ free(adres); //release memory
+ octetTotal -= memPT->taille_mem;