Game Development Community

Linux compilation

by Matthew Shapiro · in Torque Game Engine · 01/26/2002 (7:00 am) · 15 replies

I recently formatted and reinstalled Win2k and decided to try out Red Hat 7.2 . Well win2k is acting really screwed up and I should be fine in linux once i get teh WineX up and running. But right now my problem is this.. I wanted to see how torque ran in linux. Well I cna't figure out how to compile it (make in the directories gave errors). I also haven't seen any documentation on this. Any one have any ideas?

#1
01/26/2002 (8:02 am)
*g* ... RTFM once more Kall :)
The install instructions for torque come with a very detailed instructions to compile under linux
Read em please
#2
01/28/2002 (3:44 pm)
If after reading the docs you can't get it to compile, please post a message here and I'll try to help debug it.

Thanks,

- jq
#3
01/28/2002 (4:48 pm)
i still have it segfaulting :\
i added you to my icq list already.. hope to find you online some day :\
#4
01/28/2002 (5:55 pm)
Is the linux client working at all? Im not really interested in the dedicated server right now but I would like to run torque in Linux. I got the windows version running with wineX and it all worked fine except for keyboard input.

-Tim aka Spock
#5
01/29/2002 (2:04 am)
The client should be working, try it out and see.

Exodus, I added you to my icq list today and sent you a message, but I think my icq clone might be screwed up. I'll try again tomorrow.
#6
02/04/2002 (6:07 am)
After compiling the linux version, I had a segfault too when starting the demo (in client mode only, the dedicated server was working). A quick xxgdb session showed that the problem was located in the SDL code for handling RedBook audio CDs. So i just deactivated the offending code by puting a 'return;' at the beggining of the InstallRedBookDevices() function in x86UNIXRedbook.cc (who needs audio cd playpack anyway ;) and now it works fine.

I think this is a SDL bug rather than a Torque one but I haven't analyzed this bug in detail.

(BTW, that's with Torque 1.1.1, SDL 1.2.3 and Mandrake 7.2 (glibc 2.1.3))

I hope this can help some fellow penguins^H^H^H^H^H^Hlinux users.
#7
02/04/2002 (2:20 pm)
I had that same problem too, I rebooted and recompiled and it fixed the problem. My only problem now is I can't get sound to work.

-Tim aka Spock
#8
02/05/2002 (4:12 pm)
Marc, for the redbook audio problem, if you know what line the code failed on, please send it to me. In the meantime I'll take a look at the code and see if there is any evil lurking there.

Tim, for the missing audio, are you using the 11/11/01 openal drop? Thats the only version that I know works. If you use -console, are any messages about audio initialization printed out?

Thanks,

- jq
#9
02/05/2002 (5:31 pm)
thanks for the -console command..got my problem fixed. If I would have read in the torque linux compilation more careful I wouldn't have had the problem :) (I had to add the path to openal)

Im using the 11/11 version I get this in the console...is it normal?

Missing OpenAL function 'alGetBoolean', using emulated function
 Missing OpenAL function 'alGetInteger', using emulated function
 Missing OpenAL function 'alGetFloat', using emulated function
 Missing OpenAL function 'alGetDouble', using emulated function
 Missing OpenAL function 'alListeneri', using emulated function
 Missing OpenAL function 'alGetListener3f', using emulated function
 Missing OpenAL function 'alcGetContextsDevice', using emulated function

I do get sound now.

-Tim aka Spock
#10
02/06/2002 (3:53 am)
Quote:Marc, for the redbook audio problem, if you know what line the code failed on, please send it to me. In the meantime I'll take a look at the code and see if there is any evil lurking there.

John, don't worry about that. The bug was indeed in SDL. I've fixed it as it was just some bad string manipulations in a buffer that could be too small depending on the content on your /etc/mtab (and that explains why this bug only happens on some systems and why rebooting solved this problem for Tim) I'm going to send a patch to the SDL team. In the meantime, if some people have this problem here is the diff:

In the file SDL-1.2.3/src/cdrom/linux/SDL_syscdrom.c:
189c189
< mnt_type = malloc(strlen(mntent->mnt_type) + 1);
---
> mnt_type = malloc(strlen(mntent->mnt_type) + strlen(mntent->mnt_opts) + 1);
193c193
< mnt_dev = malloc(strlen(mntent->mnt_fsname) + 1);
---
> mnt_dev = malloc(strlen(mntent->mnt_fsname) + strlen(mntent->mnt_opts) + 1);
#11
02/06/2002 (4:11 am)
And after checking the SDL cvs, I saw that the bug is already fixed in it. The next version will have it. (/me grumbles: they fixed that 2 months ago, they could have released a new version and saved me the trouble.)
#12
02/06/2002 (12:45 pm)
Tim, the emulated function messages are normal. Unfortunately there are functions in the windows/creative openal implementation that are missing in the loki implementation. I had to write "emulated" functions for these.

I haven't checked any newer versions of openal for torque compatibility; perhaps these problems have been resolved. What I do know is that versions older than 11/11 were missing more functions, and versions newer (from december) had crashing problems. :(

By the way, do you get sound clicking/popping when you move the mouse over the buttons in the torque shell?

Marc, thanks for the update on the cdrom problem. Bugs in other peoples code that are already fixed are my favorite kind. :)
#13
02/06/2002 (2:55 pm)
Yeah it does click and pop a bit when moving it over them enough...is this to do with the emulated functions?

Also in the console Im getting "Unable to initialize IPX - error 5" is this normal or another setting problem I have wrong?

-Tim aka Spock
#14
02/06/2002 (5:33 pm)
I don't know what causes the click/pop. It might be my goofy emulated functions, or it might be a problem with the openal library. One of these days I really need to try a more recent openal lib. Now I know it isn't specific to my system, though.

I've seen that IPX error before. I think it has something to do with kernels that have IPX support partly or fully configured. On my kernel I have IPX disabled so I don't get the error message. There may be a linux torque bug there with IPX. Or it may be that IPX is configured in the kernel but has not been activated, so torque can't initialize it.

In any case I think the primary network protocol is TCP/IP so hopefully you shouldn't run in to any problems.
#15
02/06/2002 (6:05 pm)
Cool...actually I didn't even hear it till I turned up my sound a bit.

-Tim aka Spock