In my last post I promised to give directions about how to install STK Engine 8.02 on Ubuntu 8.04. So here it is, in a few easy steps. I used a VMware virtual machine to generate this procedure. I configured the virtual machine for 1GB of memory and an 8GB hard disk. I started from a clean install of Ubuntu using the default install settings (with dhcp enabled). I also installed the latest (at the time of this writing) Java jdk (in the /usr/java/jdk1.6.0_07 directory).
I created the video below to show the entire process. Detailed instructions follow, but if you just want to see what's involved, or if you need additional information like the output or the behavior of a specific command the video should help! Notice that the video has been created using a virtual machine, so it is slower than what you will experience on a real machine. Also a high resolution version of the video (~95MB) is available here.
Download install from ADN
To get started you need to download the Linux install archive (STKEngine802Linux.tgz) from the ADN Download section. The procedure below assumes that the archive was downloaded to your desktop, i.e. at ~/Desktop/STKEngine802Linux.tgz. If you downloaded to a different location you will need to replace this with the appropriate path on your machine.
There are a few prerequisites before we start installing on Ubuntu. On the officially supported platforms these steps are not necessary because the system comes with the required packages. For Ubuntu we need to install: c shell, stdc++5, motif and ungif. This can be accomplished through the following commands:
|sudo apt-get install csh
sudo apt-get install libstdc++5
sudo apt-get install libmotif3
sudo apt-get install libungif-bin
Install STK Engine (4DX)
Now that the required packages are laid down we can proceed with the regular installation. Uncompress the STKEngine802Linux.tgz archive by running the following command in your home directory:
|tar -xvf '~/Desktop/STKEngine802Linux.tgz'|
The archive expands to two directories: cdrom802Linux and cdrom802Disk2. Now we proceed with the install using the default settings:
Please notice that you do not need admin rights for the install: the software gets installed locally in your home directory under the ~/agi directory.
Once again Ubuntu is not officially supported. Therefore we have to make a few post-install tweaks to get things up and running.
Now edit your .bashrc startup file. At the end of the file add the following lines (see here if you are curious about MWNO_RIT):
After changing your .bashrc file make sure you close your current terminal and re-open a new one.
We also need the following symlink (if /usr/lib/libGL.so does not exist in the system you will get an error at runtime: "Unable to resolve function glXQueryExtension"):
|sudo ln -s /usr/lib/libGL.so.1 /usr/lib/libGL.so|
Our install also copies local versions of libz and libpng. On Ubuntu these libraries conflict with the versions provided with the system, so we need to "neutralize" them:
mv libz.so.1 libz.so.1.HIDE
mv libpng12.so.0 libpng12.so.0.HIDE
One last thing we need to do is to fix the run scripts accompanying the java samples. These scripts reference the libGLU.so.1 library from /usr/X11R6/lib. On ubuntu that library is at a different location: /usr/lib. So the following sed command will fix the scripts:
sed -i 's/\/X11R6//' Run*
Getting a license
At this point we are ready to start using STK Engine (4DX). Obtain a free demo license by contacting our support. Make sure that you specify that you want to evaluate on Linux. You will receive a .lic file that you need to place in your home directory.
Up and running!
You are now ready to run! Use the following steps:
This will open the 4DXDemo C++ example. You can then open the Battlespace.sc demo scenario through the File/Demo Scenarios/Scenarios menu:
We can now also compile and run the Java examples:
Here is a screenshot of the Java Sisp example:
Now that you are up and running you can browse on C++ & Java examples from the ~/agi/4DX/8.0.2/samples directory. You can also browse our help system using: