Previous Blog Next Blog
Prev/Next Blog
by date

Plan for John Vanderbeck

Plan for John Vanderbeck
Name:John Vanderbeck 
Date Posted:Apr 14, 2004
Rating:Not Rated
Public:YES
Comments:YES
RSS Feed:GarageGames Blog feedor Subscribe with .
Profile Page:View profile page for John Vanderbeck

Blog post
Linux tamed?
So I spent the day off and on taking another stab at Linux. With the Mayhem chat program rapidly maturing, I was going to need to eventually compile it under Linux so it could be run on our server. As some of you may have read, my last attempt to get Linux working as a dual boot was disastrous to put it midly, but I wasn't about to give up. After reinstalling Windows and getting things back to about the way I like them, I Ghosted my machine, and got ready to dive back into Linux.

This time I chose a much friendlier distribution; I opted for SuSE this time around. I first downloaded the "LiveEval" to see if it would run on my system, and other than a few hitches it seemed to do so. I then downloaded the boot iso, burned it, inserted it, took a DEEEP breath, and rebooted and began the installation. The installation from FTP took a god awful long time (on broadband), but after about 5 or 6 hours (no joke) everything finished and I rebooted.

Yay! I was looking at my new KDE destktop! Woot! I tamed it!

Or so I thought. My keyboard wasn't working. Gah! I use a Logitech Wireless USB keyboard, and it wasn't working. I hooked up a crappy old "normal" keyboard and it worked fine (Well fine except for the fact that its a broken keyboard and only about 7 letters on it actually work). So I then hunt around the house and find one of those neat little USB to PS2 adapters and plug my wireless base into the standard keyboard slot. It works! Yay! Using my elemtary powers of deduction learnt from Mr Holmes himself, I decided there must be a problem with the USB support in my install. After about 20 minutes of digging around KDE I finally found sound configuration options, and I noticed that what it called "Hotplugging" was already installed. Hmm. I fudged around with some settings for a bit, and suddenly my keyboard was working with the USB hookup. YAY!

I wanted to stop here and rest, but obviously this was all for not if I couldn't get Torque working and compiling. So that was my next step. First thing I did was install KDevelop 3, as i'd seen it mentioned on the forums. I then followed the instructions in the KDevelop section of the new Getting Started docs (Woot Josh!) and ran into my first problem. While SuSE was cool and mounted all my NTFS Windows drives so I could access them, I found that they were read-only. Boo. Ok, so I check out a new copy from CVS onto my Linux partition, and try again. Yay! I have Torque in KDevelop now! Loading the project file, or changing any project settings takes about 10 hours which sucks, but oh well. Build->Make. Fail! Booo! Konsole. cd !/projects/torque make -f blah blah. Back to KDevelop Build-Make it starts! Yay!

Erro you don't have nasm you moron. Boo! Install nasm package, make it goes farther. No SDL. Boo! Install SDL yay! No openAL boo! install OpenAL yay!

Then the one word that made me scream in joy.

SUCCESS

YAY YAY YAY YAY YAY!

I GOT TORQUE COMPILED IN LINUX! YAY!!!!

Ahem.

I run Torque demo. It runs! Holy cow this is cool! I've actually got Torque installed and running under Linux.

Now comes the time to deal with some issues I have no idea yet how to handle. For one, it looks like I have to maintain two seperate sources; one for Linux and one for Windows. Thats going to be a nightmare. I'm going to have to see if theres anyway to change that, because i'm not looking forward to applying all our changes again. I also need to see how to get some of our custom stuff compiled, such as SQLite. That's what i'm actually working on now.

But i've finally gotten over the top of that hill I think. I'm so happy.

Recent Blog Posts
List:04/06/05 - Plan for John Vanderbeck
04/04/05 - Plan for John Vanderbeck
02/08/05 - Plan for John Vanderbeck
08/20/04 - Plan for John Vanderbeck
05/22/04 - Plan for John Vanderbeck
05/14/04 - Plan for John Vanderbeck
05/03/04 - Plan for John Vanderbeck
04/25/04 - Plan for John Vanderbeck

Submit ResourceSubmit your own resources!

Thomas "Man of Ice" Lund   (Apr 14, 2004 at 20:19 GMT)
Create a small partition and make it non-NTFS for your Torque sources. Use partitionmagic or something similar.

Linux can mount regular fat32 drives read/write, but the read/write module for ntfs is very shaky and unreliable (afaik)

And congratulations for your first step into manhood ;-)
Edited on Apr 14, 2004 20:20 GMT

John Vanderbeck   (Apr 14, 2004 at 20:49 GMT)
Thanks for the tip Thomas. I'll give that a try later tonight.

Mike Nelson   (Apr 15, 2004 at 23:39 GMT)
Congrats!!!

This brought me back to when I first installed Linux. I just resently installed a new distro (Gentoo!) and I had to do it all over again. This is the true path to Linux mastery. :)

If you're careful you won't need to maintain two separate sources for your Torque projects. We've ported GravRally to a Linux/Windows code-line from a straight Windows project without much of a problem after a few months of putting our own stuff into the engine for the game. A big thing to look out for is that gcc is closer to the ANSI C++ standard than VC++'s compiler is so there are times when the code will not compile in gcc just because VC++ is more forgiving. So you may need to relearn some small habits. What I've seen mostly is there is stricter rules on passing params properly to functions -- make sure your passing by reference when it's required, etc.

Overall the best way to maintain the codeline in all platforms is to modify it in one and test in the others and maybe make some fixes and go around in this fashion. But with Torque you can get away with developing on your favorite platform then porting the code-line to cover the other platforms when your just about done as long as you don't mess too much with the guts of the engine.
Edited on Apr 15, 2004 23:41 GMT

John Vanderbeck   (Apr 16, 2004 at 00:02 GMT)
The thing holding me up right now is this damned archaic interface :p

In DevStudio all I have to do to add a file or link with a lib is just add it to my project. Not so in Linux :( Adding the source file to the project doesn't add it to the compile, so I have to manually add it to the makefile as well. I'm still lost as to adding libraries for linking :(

Shay Casey   (Apr 19, 2004 at 01:56 GMT)
cant you add the libs to your code with praga comment"library.lib";
lol. I have no idea why Im even suggesting this.

good luck in bad interface land : ) Why would you have to maintain 2 code bases. I thought it is supposed to run on all 3 platforms? what gives.

You must be a member and be logged in to either append comments or rate this resource.