Donate Share

JEDI-SDL : Pascal headers for SDL

Tracker: Patches

5 Fixes for 64-bit compatibility - ID: 1902924
Last Update: Attachment added ( kambi )

(This is a patch for issue #1865017 ("64 bit compatibility").)

Summary of fixes:

1. A lot of fixes to use types PtrUInt or PtrInt.

2. PixelPrachtFX/Demo/Textures.pas defined unused assembler SwapRGB
routine. This wasn't portable to x86_64, fortunately it was also completely
unused.

And PixelPrachtFX/Demo/fxBurn.pas must use this unit using "Textures" name,
that's how case-sensitive filesystem works (Pascal unit names must be in
the exact same case as declared, or all lowercase).

3. I also fixed Demos/2D/SDLTests/testalpha/, it seems that it never worked
before.

4. And I fixed ODE/Demos/RagDoll/JEDISDLRagDoll.dpr, it was never
compilable before (required "ragdoll" unit which isn't in the repository,
and actually is not needed).

5. Oh, and Delphi/Kylix don't define PtrUInt or PtrInt types. And I don't
know what are equivalents of PtrUInt / PtrInt under GPC (GNU Pascal
supports many architectures, it must have something similar to FPC's
PtrUInt / PtrInt). I added

{$ifndef FPC}
type
PtrInt = LongInt;
PtrUInt = LongWord;
{$endif}

to SDL.pas, so every unit using SDL should compile under any compiler
(under non-FPC, it will fall back to 32-bit pointers, so will work as
previously). But bear in mind that I didn't actually test it --- I don't
own Delphi anymore. Someone who does have Delphi should quickly test after
applying this patch that compilation of everything with Delphi goes fine.
And if some unit complains that PtrUInt / PtrInt is unknown --- you should
add SDL unit to it's uses clause.


Michalis Kamburelis ( kambi ) - 2008-02-27 11:13

5

Open

None

Nobody/Anonymous

None

None

Public


Comments




Log in to comment.

No follow-up comments have been posted.

Attached File ( 1 )

Filename Description Download
jedi-sdl-64bit.patch The described patch Download

Change ( 1 )

Field Old Value Date By
File Added 268248: jedi-sdl-64bit.patch 2008-02-27 11:13 kambi