fraggle
Super Moderator

Posts: 6568
Registered: 07-00 |
exp(x) said:
If you want, I can give you an ssh account on my computer if you don't have a 64-bit machine to test on. I managed to get rid of the music error; apparently I had timidity only installed in my chroot.
That's ok, I actually have an Athlon 64, I just run it with the 32-bit version of Ubuntu most of the time.
Anyway, I seem to have found the cause of your problem. In p_setup.c, change this line:
code: linebuffer = Z_Malloc (total*4, PU_LEVEL, 0);
to this:
code: linebuffer = Z_Malloc (total*sizeof(line_t *), PU_LEVEL, 0);
I only had a quick play through, but everything seem to work fine as far as I can tell.
Quasar said:
Porting DOOM to 64-bit is going to be a freaking nightmare >_<
It's not so bad. Doom is pretty portable already, although it does make a few 32-bit assumptions (like the change I listed above). Probably the worst thing it does is assume int=32 bits, short=16 bits, etc. In 64-bit Linux, only long changes (32->64), so that isn't much of a problem. Also, the level loading code makes some assumptions regarding structure packing - ie. it assumes the structures in doomdata.h are tightly packed like they are on disk. They haven't tripped me up yet so I haven't bothered to change them.
I just booted up from a Ubuntu livecd into 64-bit Linux to track this bug down. I actually already applied some 64-bit fixes ages ago to try to get it up and running - before those, it never even reached the title screen.
|