This is my first ever attempt at a guide. It is based off of the debian build guide on laanx, and on
this build guide as well. Please feel free to let me know how it works for you, as well as if I made any mistakes. Commands will be entered using the new code highlighting, and entries in text files will be colored
greenI also have a versoin of it on my site as well:
http://vaalnor.mine.nu/cvs.htmGuide to building PlaneShift on Ubuntu Dapper Drake:First off this may contain errors, so please let me know. I'll probabily be making a dapper script to handle this later on. Also note that this is a guide to compiling bleeding edge. This means it compiles the latest and greatest (or buggyies) code available. It also means that there is a possibility that even if it all builds fine, you may not be able to log into the server becase your version is too "new". I'll definately be fixing this with build dates at some point but that is more to maintain so for now this will have to do

Also note that you need to have the universe and multiverse repositories enabled for this to work. I may post how to change that later on. If you are having troubles try using my sources.list file found on gttp://vaalnor.mine.nu/sources.list In addition please make sure that you have 3d acceleration enabled before attempting this. You can test this by entering
glxinfo | grep direct and watching to see if it says direct render = yes
Well, with that out of the way lets get this party started!
Section 1: Resolving DependenciesFrom a command line run this:
sudo apt-get updateand then:
sudo apt-get --assume-yes install libjpeg62-dev x11proto-gl-dev autoconf libcurl3-dev jam bison flex-old automake1.9 jam libcurl3-dev libmng-dev libmikmod2-dev libogg-dev libvorbis-dev zlib1g-dev libpng3-dev build-essential cvs libtool libglu1-mesa-dev xserver-xorg-dev libxt-dev libopenal0a libopenal-dev subversionSection 2: Setting up Build EnvironmentNext get yourself a working directory to compile in. I usually prefer to install in /opt so I do as follows:
sudo mkdir /opt/planeshift_cvssudo chmod a+rw /opt/planeshift_cvsand then
cd /opt/planeshift_cvsahh thats better! Now that we are in our new working directory and have permission to write there lets move on!
Section 3: Checking Out Source Code From CVS and SVNcvs -d:pserver:anonymous:@planeshift.cvs.sourceforge.net:/cvsroot/planeshift loginand hit enter
then type:
cvs -z3 -d:pserver:anonymous@planeshift.cvs.sourceforge.net:/cvsroot/planeshift co planeshiftand hit enter.
this will throw a bunch of text on your screen blah blah blah. The long short of this is that you now have a new directory called planeshift
in the directory you are in now. It contains the latest cvs source code! FUN!
go ahead and enter that directory like so:
cd planeshiftNow we\'ll get the latest source to planeshifts dependacies - Cal3d, Crystalspace, and CEL!
enter this:
cvs -d:pserver:anonymous:@cal3d.cvs.sourceforge.net:/cvsroot/cal3d loginand hit enter
and then enter this:
cvs -z3 -d:pserver:anonymous@cal3d.cvs.sourceforge.net:/cvsroot/cal3d co cal3dMore text.... scrolling alll alllllong the screen! Yay! OK once thats finished lets grab CrystalSpace like this:
svn co https://svn.sourceforge.net/svnroot/crystal/CS/trunk csand hit enter
once that finishes lets get CEL!
svn co https://svn.sourceforge.net/svnroot/cel/cel/trunk celhit enter of course!
Section 4: Setup Environment Variablestype this to open a file for editing.
gedit profileand paste the following lines into the file.. be sure to change the paths if you choose to install in a different directory:
export LD_LIBRARY_PATH=/opt/planeshift_cvs/planeshift/cal3d/src/cal3d/.libs/:$LD_LIBRARY_PATH
export CRYSTAL=/opt/planeshift_cvs/planeshift/cs
export CEL=/opt/planeshift_cvs/planeshift/cel
export CSCONFPATH=/opt/planeshift_cvs/planeshift/cel
export CAL3D=/opt/planeshift_cvs/planeshift/cal3d
now save the file and exit ? then enter this:
source profileif there are no errors then you probably did it correctly.
Section 5: Compilingcd into the cal3d directory that was created when you checked out cal3d from cvs like so:
cd cal3dand then enter this:
./autogen.shand then:
./configure --prefix=$CAL3Donce this configure completes, you are ready to build!
go ahead and type the following ? it won\'t take too long so stick it out:
makeand once that is done type
make installif it errors out and you see an error like this:
g++: @all_libraries@: No such file or directory
Then enter this command:
sed -i 's/all_libraries = @all_libraries@/#all_libraries = @all_libraries@/' /opt/planeshift_cvs/planeshift/cal3d/src/cal3d/Makefile.amThen redo your build like so:
./configure --prefix=$CAL3Dmakemake installif there were no errors then we are ready to go on to the next step ? which for me was always the toughest. We'll be building CrystalSpace. Now if the install of cal3d failed, type ./configure ?prefix=$CAL3D again and watch for the things it is checking for ? you can scroll in your gnome terminal to see it all once it is done. if you see: checking for.... blah blahc......no then try looking for similar files in synaptic to install and try again.
OK whew! Now lets compile crystalspace!
enter this to get to the crystalspace directory:
cd ../csNow that we are there go ahead and run
./configure --without-python --without-java --with-cal3d=$CAL3Donce that finishes, run:
jam -aq libs plugins cs-config walktestand take a nap, get a cup of tea or amuse yourself some other way. Because this is going to freaking take forever.
Once that has FINALLY finished, test it by entering
./walktest -fullbrightif you get a little 3d environment you can run around in then all is good! If there are errors then StarsandBars made this suggestion which you might try;
Sometimes you might have to use --with-libcel=/path/to/cel in CS compilation.
Using the paths I suggested, it would be --with-libcel=/opt/planeshift_cvs/planeshift/cel
Now time to build CEL! Hurray we\'re getting closer. - enter this:
cd ../celand then do an:
./autogen.shwhen that finishes ? type this:
./configure --without-pythonand when that gets done... get this... type:
jam -aqhurray this one doesn\'t take nearly as long as crystalspace!! Huzzah for sanity!!!
Guess what? Now we get to compile planeshift! Hurray!
first do this:
cd ..and then do this:
./autogen.shand follow it with this:
./configure --with-cal3d=$CAL3D --with-cel-prefix=$CELnow that that is done, go ahead and run this:
jam -aq clientwhew that was a chore! If you are lucky and everything worked, you could go ahead and enter this:
lsand if you see a file called psclient, updater, and pssetup among the files listed (they will probably be in green) then we are doing great! Soooo... now what.... still more waiting ahead so don\'t worry. We still need to modify some stuff...
Section 6: Necessary Tweaksgedit updaterconfig.xmllook for this line:
<whole_zips>0</whole_zips>
and change it to read:
<whole_zips>1</whole_zips>Then find this:
<autoinclude_os>1</autoinclude_os>
and change it to read
<autoinclude_os>0</autoinclude_os>Then, keep on going down until you see this part:
<mirrors>
<active id=\"1\" />
<mirror id=\"1\" name=\"local\" url=\"
http://192.168.2.19/updater/\" />
<mirror id=\"2\" name=\"mirror\" url=\"
http://192.168.2.12/\" repository=\"repos.zip\" versioninfo=\"ver.dat\" />
</mirrors>
replace with this:
<mirrors>
<active id=\"1\" />
<mirror id=\"1\" name=\"mir1\" url=\"http://psmirror.pfdev.net/psupdater/\" repository=\"repository.zip\" files=\"\" />
<mirror id=\"2\" name=\"mir2\" url=\"http://planeshift.mirror.thumbnail.cz/psupdater/\" repository=\"repository.zip\" files=\"\" />
<mirror id=\"3\" name=\"mir3\" url=\"http://www.psmirror.org/psupdater/\" repository=\"repository.zip\" files=\"\" />
<mirror id=\"4\" name=\"mir4\" url=\"http://psmirror.u24.solone.net/psupdater/\" repository=\"repository.zip\" files=\"\" />
<mirror id=\"5\" name=\"backp\" url=\"http://laanx.fragnetics.com/updater_hidden/\" repository=\"repository.zip\" files=\"\" />
</mirrors>now save the file and exit.
now enter this:
./updater --autoonce that finally finally finally finishes downloading the art you can now make a little startup script to make sure all variables are loaded correctly. Start by entering this:
gedit runplaneshift.shSection 7: Launcher Scripts & Running PlaneshiftLets start by opening a new file for editing:
gedit runplaneshift.shand adding these lines:
#
#!/bin/sh
#
source profile
export MALLOC_CHECK_=0
./psclient
once that is finished, save the file and exit. then enter this command:
chmod a+x runplaneshift.shso now to start planeshift all you have to do is enter at command prompt:
cd /opt/planeshift_cvs/planeshift./runplaneshift.shif you want to add a gnome menu entry you can do so by right-clicking on the applications menu and hitting edit menus.
Go to the games part on the left and click it. Then click on the File menu and select ?New Entry?
enter the following:
Name: PlaneShift
Comments: Free MMORPG
Command: /opt/planeshift_cvs/planeshift/runplaneshift.sh
And browse to an icon if you want to.
And there you have it! You should how have a functioning PlaneShift on your system.
please let me know if this can be improved any way, or if I have made any mistakes. Also, Dapper users, let me know how this works for you and if I left out any dependencies as I was punching those out from memory.
If you get segmentation faults that usually means that there is a bug in the cvs you are trying to build, and not anything to do with the steps you took too build.. try a different build date besides bleeding edge, or try the next day.