Register  |  FAQ  |  Search  |  Memberlist  |  Usergroups  |  Log in 
Reply to topic
 PU for Linux - Compiling and Installing 
nphillips
Java Junkie
Java Junkie

Joined: 21 Jun 2007
Posts: 842
Location: lurking.
Reply with quote
Edited to change to the new url https://svn.wcjunction.com/priv_pu/trunk --wolphin
Edited again to change user as username to make people change the url. --wolphin

In order to run Parallel Universe, you will need to have a copy of PU from our svn server, as well as the vegastrike codebase from their svn.

First, create the directory in which you want to build PU. In this example, we will call the directory "pu" and it will be located in the root of your home directory. e.g. /home/user/pu

Inside of the pu folder, you will want to check out both the PU and VS svn repositories.

To check out PU, enter the following (yes, the anonymous login is username/password):
Code:
svn co --username username --password password https://svn.wcjunction.com/priv_pu/trunk priv_pu


When prompted to accept/reject the certificate, hit "p" to permanently accept it.

Once the PU repository is finished downloading, you should now see the folder "priv_pu" (/home/user/pu/priv_pu).

Now, download the VS repo:
Code:
svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/vegastrike vegastrike


When this is finished, you will have the "vegastrike" folder (/home/user/pu/vegastrike).

Vegastrike has a list of dependencies. Most of them are standard with the more popular distributions, but, some like Boost, Openal and GLUT are not. The dependencies worth mentioning are:
  • automake at least version 1.5
  • autoconf at least version 2.53
  • libpng + libpng-devel (libpng 3 is recommended)
  • python and python-dev (2.2.1)
  • expat
  • (lib)jpeg + libjpeg-devel
  • glut + glut-devel
  • openal + openal-devel

You can see the entire list here (as well as detailed instructions for compiling).

Once you're sure you have all of the appropriate dependencies installed, the compilation process is fairly straightforward. Move inside of the vegastrike directory and enter
Code:
./bootstrap-sh
This will run the automake/autoconfig tools which prepare the build. It shouldn't take very long at all.

When that is done, you need to run the traditional configure script. At a bare minimum, it will need one variable passed to it: "with-data-dir". The value for this is a path to the priv_pu data you downloaded (direct or relative, it doesn't matter). Again, for our example, the directory is "/home/user/pu/priv_pu/"
Code:
./configure --with-data-dir=/home/user/pu/priv_pu


Finally, run make.
Code:
make

Alternatively, for debugging purposes, you can run:
Code:
make > make.log 2>&1
This will provide a file called make.log which has all of the output. It will help us (and the VS forum) figure out what might be wrong.

If everything proceeds normally, you'll have succeeded in compiling Vegastrike with the Privateer Universe mod! But before you get too exicted, there's one last step -- the executable files need to be softlinked inside of the data directory.

First, cd back into the priv_pu folder. Then (again, using our example directories; adjust as needed):
Code:
ln -s ../vegastrike/vegastrike
ln -s ../vegastrike/vssetup


First run vssetup from inside of the priv_pu folder to set up your audio/graphics options. Then, run vegastrike to play the game.

If you have any trouble compiling, feel free to ask questions here, but don't forget to look around at the VS Wiki and VS Forums. The game engine and compile process is theirs; we're just modifying the game itself.

Attention:
As per Revision 67 onwards, after SVN Checkout or after every SVN Update you need to move (NOT copy) the .pu folder from under your game's root folder to
your home directory.. ~/ (overwriting).
You also have to copy vegastrike.config from your game's root folder to ~/.pu


Last edited by nphillips on Thu Jan 10, 2008 4:44 am; edited 2 times in total

_________________
homepage | projects | comic| tadpole| privateer
R. Buckminster Fuller wrote:
Everything you've learned in school as "obvious" becomes less and less obvious as you begin to study the universe. For example, there are no solids in the universe. There's not even a suggestion of a solid. There are no absolute continuums. There are no surfaces. There are no straight lines.
View user's profile Send private message Visit poster's website AIM Address
  
Dilloh
Symphatizer
Symphatizer

Joined: 22 Jun 2007
Posts: 1301
Location: Black Forest, Germany
Reply with quote
That's great - please put this in our FAQ on the main page
View user's profile Send private message
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
That was Nate's original intent; but he couldn't have html links there; so I suggested to him to make it an announcement for now, and then research how vista included a special file in the Downloads section; and try to do the same for the news and faq sections.

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
loki1950
VS Consul General

Joined: 24 Aug 2007
Posts: 1121
Location: Ottawa
Reply with quote
I will be helping anyone who tries same as on the VS forums so just post the failed configure log or make output lots of work arounds in the Compiling Problems forum if there is a need Wink

Enjoy the Choice Smile

EDIT: avoid the beta nVidia series 169 there is a bug in it's handling of compressed textures so stick with the stable 100 series
View user's profile Send private message MSN Messenger
  
BTL
Ejected Pilot
Ejected Pilot

Joined: 04 Jan 2008
Posts: 42
Reply with quote
nphillips: the instruction is fine. Great work. Very Happy

but the bootstrap file has a '-' instead of an '.'.
Not really big, but maybe there will be some users just changed from Micro$oft. Not having to much overview and are tending for leaving things alone instead making anything wrong or even worse: broken.
(Hope this sentence is no complete rubbish)

Additionally, there could be added an entry with the make command. It's not necessary, but running make, piping the output to a file like 'make > make.log 2>&1' will make debugging much easier.
I know: this extension is not in the vs-wiki either but you can find it in some places in the Forum.

Just tested and it works all fine.
Smile


Last edited by BTL on Thu Jan 10, 2008 7:26 am; edited 1 time in total
View user's profile Send private message
  
nphillips
Java Junkie
Java Junkie

Joined: 21 Jun 2007
Posts: 842
Location: lurking.
Reply with quote
BTL wrote:
nphillips: the instruction is fine. Great work. Very Happy

but the bootstrap file has a '-' instead of an '.'.
Not really big, but maybe there will be some users just changed from Micro$oft. Not having to much overview and are tending for leaving things alone instead making anything wrong or even worse: broken.
(Hope this sentence is no complete rubbish)

Additionally, there could be added an entry with the make command. It's not necessary, but running make, piping the output to a file like 'make > make.log 2>&1' will make debugging much easier.
I know: this extension is not in the vs-wiki either but you can find it in some places in the Forum.

Just tested the install in a and it works all fine.
Smile
Excellent.

Good catch on the "bootstrap-sh" thing. I use tab-completion all the time, so I just assumed...

Changes made, including the make log. Good tip.

_________________
homepage | projects | comic| tadpole| privateer
R. Buckminster Fuller wrote:
Everything you've learned in school as "obvious" becomes less and less obvious as you begin to study the universe. For example, there are no solids in the universe. There's not even a suggestion of a solid. There are no absolute continuums. There are no surfaces. There are no straight lines.
View user's profile Send private message Visit poster's website AIM Address
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
Attention Linux and Mac users: After installing, you need to manually copy or move the /.pu folder from under the game's root folder (used to be called .privateer100), to right under ~/ (an installer that does this would be nice, but, for now anyways).

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
loki1950
VS Consul General

Joined: 24 Aug 2007
Posts: 1121
Location: Ottawa
Reply with quote
That's a move not copy as leaving the copy in the game root folder will confuse the engine Cool

Enjoy the Choice Smile
View user's profile Send private message MSN Messenger
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
I'll update the instructions, then; thanks!

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
Nate, it would be nice to have a script for this, if it's possible. Actually, after EVERY SVN-Update the .pu folder will be restored, which may be a problem, if, as reportedly, the engine can get confused...
How about a script for Linux users that does the SVN-Update AND moves the .pu folder?

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
Another idea: Perhaps what would be best for Linux users would be to put an empty .pu folder under the
game's root folder and turning it into a symbolic link to ~/.pu --so that SVN Update's don't re-create the
.pu folder, and so that any updates to files under .pu go to the right place. This could be added to the
script...

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
nphillips
Java Junkie
Java Junkie

Joined: 21 Jun 2007
Posts: 842
Location: lurking.
Reply with quote
chuck_starchaser wrote:
Another idea: Perhaps what would be best for Linux users would be to put an empty .pu folder under the
game's root folder and turning it into a symbolic link to ~/.pu --so that SVN Update's don't re-create the
.pu folder, and so that any updates to files under .pu go to the right place. This could be added to the
script...
Except that under Linux, symlinks are treated as "real" files. If the engine gets confused at the real .pu folder being in the main directory, it's going to get confused with the symlink. When browsing the folders, for all intents and purposes, the symlinked folder will show all of the files in the linked-to directory.

My question is: why does the engine get confused by this? I've never had to move the .privateer100 folder out previously. Was it even there, before? If so, what changed? Certainly there's a way to use a conditional statement to check first for ~/.pu and if it doesn't exist, fall back to datadir/.pu.

But, in answer to the original question: Yes, I could easily cook up a script that does all of that.

_________________
homepage | projects | comic| tadpole| privateer
R. Buckminster Fuller wrote:
Everything you've learned in school as "obvious" becomes less and less obvious as you begin to study the universe. For example, there are no solids in the universe. There's not even a suggestion of a solid. There are no absolute continuums. There are no surfaces. There are no straight lines.
View user's profile Send private message Visit poster's website AIM Address
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
Well, my guess would be that there'd be some bug somewhere that checks for the existence of .privateer100 or whatever, under the game folder, --before checking into the home folder. If so, a sym link would mask the bug, which is a bad thing; but on the other hand, would work. And if the engine gets confused by the sym link, then I'd say we'd better get to the bottom of it, because a sym link is just what the doctor recommended, in terms of SVN updates, anyways; isn't it?

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
nphillips
Java Junkie
Java Junkie

Joined: 21 Jun 2007
Posts: 842
Location: lurking.
Reply with quote
I'm not sure if a symlink would work, or not. It all depends on how SVN reads it. Bit-wise, a directory and a symlink are different, so it may register it as an inconsistency.

Plus, one thing I'm thinking about is callously moving the .pu folder. If, after updating, we move .pu it could potentially ruin any existing customized files in the user's preexisting folder.

I'll play around with a script tonight. It shouldn't be too terribly hard.

_________________
homepage | projects | comic| tadpole| privateer
R. Buckminster Fuller wrote:
Everything you've learned in school as "obvious" becomes less and less obvious as you begin to study the universe. For example, there are no solids in the universe. There's not even a suggestion of a solid. There are no absolute continuums. There are no surfaces. There are no straight lines.
View user's profile Send private message Visit poster's website AIM Address
  
chuck_starchaser
SecretOps
SecretOps

Joined: 21 Jun 2007
Posts: 6291
Reply with quote
Edited first post once again, to add the pu versus .pu issue with Version.txt

EDIT:
The above is obsolete. Revision 72 was in error. Version.txt should say...
.pu ("dot"-pu), as corrected in Rev 73.

Removed the last edit, as well as stuff I added earlier about copying savegames
from .privateer100, which was not germain to installation.

_________________
WCpedia --The Wing Commander Encyclopedia
WC Nexus forum, the Moonbase Tycho of WC fans.
View user's profile Send private message
  
loki1950
VS Consul General

Joined: 24 Aug 2007
Posts: 1121
Location: Ottawa
Reply with quote
bit of a time saver for those that also build the vegastrike binary for vegastrike's data set it is not necessary to configure with
Code:
-with-data-dir=/home/user/pu/priv_pu

so you only have to build it once per update Very Happy

Enjoy the Choice Smile
View user's profile Send private message MSN Messenger
  
javier
Recon Probe
Recon Probe

Joined: 08 Feb 2008
Posts: 29
Reply with quote
Does somebody know if it is possible to compile the vegastrike binaries only once and use it against the two data sets setting some environment variable?
View user's profile Send private message
  
wolphin
Least Claw
Least Claw

Joined: 22 Jan 2008
Posts: 672
Location: Gentoo
Reply with quote
Yeah, build it with data dir to a symlink, and change the symlink to point to the mod you want to play.

For example, if the svn checkout for vegastrike, priv_pu and data4.x are in the same directory we'll call /vs, you can
Code:
cd /vs
ln -s data4.x data
cd vegastrike
./bootstrap-sh
./configure --with-data-dir=../data


Then you change the symlink to play the other mod, like so
Code:
cd /vs
rm data
ln -s priv_pu data
cd vegastrike
./vegastrike


I made scripts to do that for me.
View user's profile Send private message
  
loki1950
VS Consul General

Joined: 24 Aug 2007
Posts: 1121
Location: Ottawa
Reply with quote
It is also possible to run in a copy of the data tree and copy/paste the binaries into the bin folder and create the symbolic link with Gnome i just right-click, as i have mentioned before i like to keep my base svn repository clean.

Enjoy the Choice Smile
View user's profile Send private message MSN Messenger
  
javier
Recon Probe
Recon Probe

Joined: 08 Feb 2008
Posts: 29
Reply with quote
wolphin wrote:
Yeah, build it with data dir to a symlink, and change the symlink to point to the mod you want to play.

For example, if the svn checkout for vegastrike, priv_pu and data4.x are in the same directory we'll call /vs, you can
Code:
cd /vs
ln -s data4.x data
cd vegastrike
./bootstrap-sh
./configure --with-data-dir=../data


Then you change the symlink to play the other mod, like so
Code:
cd /vs
rm data
ln -s priv_pu data
cd vegastrike
./vegastrike


I made scripts to do that for me.

Doesn't work for me. I'll build binaries twice.
View user's profile Send private message
  
wolphin
Least Claw
Least Claw

Joined: 22 Jan 2008
Posts: 672
Location: Gentoo
Reply with quote
Without knowing what fails I don't see what the problem is, but you could always move the actual data4.x or priv_pu directory to data before execution.
View user's profile Send private message
  
gorbalad
Enlisted Pilot
Enlisted Pilot

Joined: 17 Mar 2008
Posts: 2769
Location: Vienna, Austria Timezone: GMT+1 in winter, +2 in summer
Reply with quote
I tried to compile PU under ubuntu8.04 64bit...
the compiling failed, and the only error I could find was:
Code:
/usr/bin/ld: cannot find -lvorbisfile

make.log (some stuff in german, I could translate if needed)

_________________
Ceterum Censeo...
View user's profile Send private message
  
nphillips
Java Junkie
Java Junkie

Joined: 21 Jun 2007
Posts: 842
Location: lurking.
Reply with quote
Check to make sure you have (ogg)vorbis libraries installed.

_________________
homepage | projects | comic| tadpole| privateer
R. Buckminster Fuller wrote:
Everything you've learned in school as "obvious" becomes less and less obvious as you begin to study the universe. For example, there are no solids in the universe. There's not even a suggestion of a solid. There are no absolute continuums. There are no surfaces. There are no straight lines.
View user's profile Send private message Visit poster's website AIM Address
  
gorbalad
Enlisted Pilot
Enlisted Pilot

Joined: 17 Mar 2008
Posts: 2769
Location: Vienna, Austria Timezone: GMT+1 in winter, +2 in summer
Reply with quote
nphillips wrote:
Check to make sure you have (ogg)vorbis libraries installed.

hmm... if I could only find out how that package's name might be... *googling*
EDIT: vorbis-tools - now trying again.

_________________
Ceterum Censeo...
View user's profile Send private message
  
gorbalad
Enlisted Pilot
Enlisted Pilot

Joined: 17 Mar 2008
Posts: 2769
Location: Vienna, Austria Timezone: GMT+1 in winter, +2 in summer
Reply with quote
gorbalad wrote:
nphillips wrote:
Check to make sure you have (ogg)vorbis libraries installed.

hmm... if I could only find out how that package's name might be... *googling*
EDIT: vorbis-tools - now trying again.

hmm. the same error... probably that wasn't enough.
EDIT: But I'm able to play .ogg, with totem, mplayer and ogg123 at least Smile

_________________
Ceterum Censeo...
View user's profile Send private message
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT  
Page 1 of 5  

  
  
 Reply to topic