PDA

View Full Version : Compile under Linux!?


=X=Master HeX
11-28-2003, 09:36 AM
What in god's name were they thinking when they moved off of .vm files and went to .dll files. Now, as far as I can tell, their little readme tutorial shows you how to make the dll files for windows servers... How in the world do you compile the linux .so needed for linux dedicated servers?

=X=Master HeX
11-28-2003, 11:43 AM
Answering my own question:
http://divoid.net/downloads.html

This person was kind enough to make a patch file for the game directory source code. Just download it and throw it in your game folder then use the patch command with it to patch the code. A make will make the so file needed for linux dedicated server.

On a side note I can't get it to compile under cygwin. It errors out when attempting to make all of the .o files. Any assistance would be wonderfull.

Wudan
11-28-2003, 02:00 PM
You might be the only one in that boat. However, it should be noted that the Win-compiled DLLs will run on a Linux Dedicated Server.

I'm not compiling with MSVC, I'm attempting to compile with MingW, which is Minimalist Gnu for Windows, so I'm sort of in the same boat as creating my own project and/or makefiles.

razorace
12-01-2003, 03:44 AM
So how do you run .dlls on the linux dedicated server? I never use Linux and need instructions so I can help people that ask.

zERoCooL2479
12-01-2003, 05:37 AM
The good thing is, we are all going to learn something new :-)

Extra creases in the brain rule! I'm pretty much in the same boat as all of you. I really think they should have kept the "vm" format, was much easier for us. In any case, if you guys find out how to do this, other than those patch files, it would be much appreciated.

Take Care!

Leg0r
12-02-2003, 08:30 PM
has anyone tried using win compiled dll's on a linux dedicated server? need confirmation that it works.

if it doesnt work, is there an easy way to convert win compiled dll's to the those linux so's? i guess there isnt :\

Janos Oudrin
01-06-2004, 12:19 AM
The patch is good indeed, but the Makefile needs tweaking.
For example, you need to add -DFINAL_BUILD to the CFLAGS to get it out of a crash-galore halfway debug mode.
After doing this I'm STILL getting a lot of crashes, especially in seige.
When I compile the same source on my windows box using the Win32 Release config, it works just fine.

Does anyone know which CFLAGS need to be added or removed?

divoid
01-06-2004, 09:33 AM
maybe your using an older compiler than i am. i wrote the patch and tested it with gcc 3.2.3 and glibc 2.3.1. Ive run the mod in various game modes for weeks at a time and ive only had it crash on me once. so its most likely something on your end

Emon
01-07-2004, 03:12 AM
Originally posted by razorace So how do you run .dlls on the linux dedicated server? I never use Linux and need instructions so I can help people that ask.

Same way it does in Windows I assume. Loading a DLL shouldn't be any different from loading an SO, other than maybe the binary needing to support it, which JA obviously does. I know Wine can load a variety of Windows DLLs without a hitch.

MasterSidious
01-28-2004, 05:06 PM
I tried the patch link and it didn't work :(. But anyway, is it possible to just use dlls for linux instead of so?

[ONE]Mushroom
01-29-2004, 11:14 AM
The patch:

http://www.lucasfiles.com/index.php?s=&action=file&id=367

You might like to check the two Linux threads I've posted here too.

MasterSidious
01-29-2004, 07:07 PM
I put the .patch file in my codemp directory then ran this line:
"C:\Program Files\LucasArts\Star Wars Jedi Knight Jedi Academy\GameData\codemp\jamp_game-2.patch" -p1 -i patch

and it can't run it cause it doesn't know about that file type. What program should I use to run this?

zERoCooL2479
01-29-2004, 10:51 PM
Originally posted by Janos Oudrin
The patch is good indeed, but the Makefile needs tweaking.
For example, you need to add -DFINAL_BUILD to the CFLAGS to get it out of a crash-galore halfway debug mode.
After doing this I'm STILL getting a lot of crashes, especially in seige.
When I compile the same source on my windows box using the Win32 Release config, it works just fine.

Does anyone know which CFLAGS need to be added or removed?

This is what I have in my CmakeLists.txt file:

-w -DQAGAME -D_JK2 -D__linux__ -DFINAL_BUILD -static

with or without the static, its up to you...

Good Luck

MasterSidious
01-29-2004, 11:49 PM
Can't get it to load period. :(

[ONE]Mushroom
01-30-2004, 08:11 PM
Originally posted by MasterSidious
I put the .patch file in my codemp directory then ran this line:
"C:\Program Files\LucasArts\Star Wars Jedi Knight Jedi Academy\GameData\codemp\jamp_game-2.patch" -p1 -i patch

and it can't run it cause it doesn't know about that file type. What program should I use to run this?

Execute the patch script under Linux. You'll need to run make under Linux too.

Alternatively you could open up the file in a text editor, see for yourself the changes that need to be made, and make them manually.

BTW, I am deeply skeptical of the possibility of a Linux server being able to use the Windows .dll

MasterSidious
01-30-2004, 09:48 PM
How do I run the patch under Linux if I don't have a Linux system? Is this even possible?