paragui-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[paragui-dev] paragui fix for 64bit


From: Ingo Schmid
Subject: [paragui-dev] paragui fix for 64bit
Date: Thu, 20 Jan 2005 19:40:24 +0100 (MET)

Hi,

I was bored some (long) time ago and tried to install some game that used
paragui on amd64 but it didn't compile. Playing aroud a little bit I got it
to work. It's the reinterpret_cast that makes problems. Find the ideas how
to fix it. 

Sorry that it isn't a patch, just a pointer where to look (I have no idea
how to make a patch, my first look into c++, almost).

Best regards
Ingo

============================

Fixing paragui for amd64 is quite simple. Basically the issue is that
unsigned int32 and pointer are the same on 32 bit plattforms.

replace 32 / 64 in pgtimerobject.cpp, here is a diff with the fix: Also
adapt the .h file.

=======================

typedef Uint64 PG_TimerID;
static Uint64 objectcount;




c/core/pgtimerobject.cpp:

3c3
< Uint32 PG_TimerObject::objectcount = 0;
---
> Uint64 PG_TimerObject::objectcount = 0;
31c31
< if(objectcount == 0) {
---
> if(objectcount == 0) {
58c58
< Uint32 PG_TimerObject::eventTimer(PG_TimerID id, Uint32 interval) {
---
> Uint64 PG_TimerObject::eventTimer(PG_TimerID id, Uint32 interval) {
62c62
< Uint32 PG_TimerObject::eventTimer(Uint32 interval) {
---
> Uint64 PG_TimerObject::eventTimer(Uint32 interval) {
67a68
> timermap[id]->sigTimer(timermap[id], id);
72a74
> objSingleTimer->sigTimer(objSingleTimer, (PG_TimerID)0);

-- 
GMX im TV ... Die Gedanken sind frei ... Schon gesehen?
Jetzt Spot online ansehen: http://www.gmx.net/de/go/tv-spot




reply via email to

[Prev in Thread] Current Thread [Next in Thread]