Preface:
It’s been a “few” years since I made the post about building the Firestorm Viewer on Ubuntu back in 2011.
(I did pretty much step out of SL sometime about 2015 for the most part after a good SL friend stepped away to start an RL family.)
“ForestAurora” is a pseudonym, my real SecondLife name was quite well known among the RLV community circa 2009.
I decided recently to take a look on SecondLife again to see what’s changed.
I use Linux 95% of the time, specifically Arch-based distros, and I noticed the info online mostly referred to building Secondlife/Firestorm viewers for Ubuntu LTS versions.
After some digging online in a blog post at http://www.xenh.at/, I managed to find what libraries were required for compiling Firestorm 64-bit on ArcoLinux.
I was inspired to make this new guide after stumbling across the blog of someone I used to know in SL: https://beccapet.com/ (Hi Becca)
Getting ArcoLinux
Arch-based distros are “bleeding-edge” so often receive updates daily.
There are several Arch-based distros, but ArcoLinux (Plasma/KDE edition) is currently my favourite so here is my guide:
Please note: I have proof tested my guide on a “bare metal” (native ArcoLinux install) system, and in a “virtual machine”, and it crashed the terminal app during compiling for some reason on the “virtual machine” (your mileage may vary),
so I can only recommend following my guide on “bare metal” systems.
Download the distro from here:
You can use Balena-Etcher software to burn the ISO onto a USB-stick:
The installer has quite a comprehensive list of apps that can be installed as part of the install process, but for the purpose of this guide I suggest selecting the “Easy Installation (Offline)” option.
Once installed, open Terminal/Konsole and type:
archlinux-tweak-tool
Once ArchLinux-Tweak-Tool is opened, click the “Pacman” tab on the left,
and at the bottom of the window click the checkbox next to “Enable Chaotics repo – set as last repo”.
Also make sure the checkboxes are enabled next to “ArcoLinux 3rd-party repo” and “ArcoLinux x-large repo” at the top of the window.
Then click “Update pacman databases” at the top of the window and wait a moment until a notification at top of the window says something about databases being updated.
Close ArchLinux-Tweak-Tool and in Terminal type:
update
When all the latest updates have been installed we need an additional tool called “Paru”, (this is installed by default on ArcoLinux), but if you are using another Arch-based distro type the following in Terminal:
sudo pacman -S paru-bin
We can now proceed to setup the build environment.
Setup the ArcoLinux build environment:
There’s a lot of files required, but some are already installed by default when installing ArcoLinux.
The full list of libraries are:
acl alsa-lib alsa-oss alsa-plugins atk attr base-devel bc bison bzip2 cairo celt cmake dbus-core e2fsprogs expat flac flex fontconfig freetype2 gcc gcc-libs gdk-pixbuf2 gettext giflib glew glib glib2 glibc gmp gnutls gtk gtk2 inetutils json-c keyutils krb5 lcms libao libasyncns libcanberra libcanberra-pulse libcap libcups libffi libgbm libgcrypt libgpg-error libice libidn libjpeg-turbo libldap libltdl libmikmod libmng libogg libpciaccess libphobos libpng libpulse libsamplerate libsm libsndfile libssh2 libstdc++5 libtiff libvorbis libx11 libxau libxcb libxcomposite libxcursor libxdamage libxdmcp libxext libxfixes libxft libxi libxinerama libxml2 libxmu libxrandr libxrender libxss libxt libxtst libxv libxvmc libxxf86vm mesa mesa-demos mpg123 multilib-devel ncurses nettle openal openssl osmesa p11-kit pango pcre pixman qt4 readline sdl sdl_image sdl_ttf speex sqlite3 tdb util-linux v4l-utils xcb-util zlib
But these are the commands i used to install the extra files:
mkdir ~/src
cd src
wget https://github.com/Kitware/CMake/releases/download/v3.18.0/cmake-3.18.0.tar.gz
tar xvf cmake-3.18.0.tar.gz
cd cmake-3.18.0
./bootstrap --parallel=$(nproc) --prefix=/usr && make -j $(nproc) && sudo make install
sudo pacman -S python-pip
python --version
sudo rm /usr/lib/python3.11/EXTERNALLY-MANAGED
sudo pip3 install --upgrade pip
sudo pacman -S alsa-oss apr-util celt glew libcanberra libmikmod libphobos libstdc++5 libxcrypt-compat libxvmc mesa-demos qt4 sdl_image sdl_ttf
When typing the following “paru” commands in Terminal it will search for the relevant files. The most relevant file is usually at the bottom of the search results and you type the number next to the file you want to install and hit enter:
paru glib
paru glew-osmesa-git
paru gtk
paru sdl
If you have an Nvidia graphics card, you’re going to need this:
sudo pacman -S nvidia-utils nvidia-libgl
Get the Firestorm viewer source code:
cd ~/src
git clone https://github.com/FirestormViewer/phoenix-firestorm.git
This will download a copy of Firestorm viewer source code.
Install Autobuild the get the build variables:
cd ~/src
sudo pip3 install git+https://github.com/secondlife/autobuild.git#egg=autobuild
git clone https://github.com/FirestormViewer/fs-build-variables.git
Get FmodStudio (Optional):
By default the viewer uses OpenAL for audio but if you want to use FmodStudio instead, (apparently its improves audio):
cd ~/src
git clone https://github.com/FirestormViewer/3p-fmodstudio.git
cd ~/src/3p-fmodstudio
The following instruction for getting the required files to build FmodStudio was mostly pasted from the Official Firestorm linux guide:
Using your File Manager, open the file called "build-cmd.sh" using a text editor (it's located in "~/src/3p-fmodstudio") and look at the fifth line down, it begins with FMOD_VERSION. This is the version of the API you need to download.
The FMOD Studio API can be downloaded HERE (requires creating a free account to access the download section). Log in as needed, then go to https://www.fmod.com/download. Click FMOD Engine to expand the section.
Click the button representing the version you're after, then click the Download link for the Linux file.
Copy that file to the ~/src/3p-fmodstudio directory.
Now this step is a bit janky but I had to do it in this precise order or it wouldn’t build the FmodStudio file:
cd ~/src/3p-fmodstudio
export AUTOBUILD_VARIABLES_FILE=$HOME/src/fs-build-variables/variables
autobuild build -A 64 --all
There will be an Error but it’s OK, you now need to edit “build-cmd.sh”, and on the 3rd line down you need to change it from:
FMOD_DOWNLOAD_BASE="http://erebus/dev/pkg/"
And replace it with:
FMOD_DOWNLOAD_BASE="http://localhost/dev/pkg/"
and save the file. Then run the following:
autobuild build -A 64 --all
autobuild package -A 64
I had tried editing the 3rd line before doing the FmodStudio build process but it wouldn't work (hence the janky step above).
(Credit to https://beccapet.com/ for pointing out the need to edit this file as it wasn’t mentioned on the Official Firestorm Linux compile instructions).
Near the end of the output you will see the package name.
Also type the following to see the md5 hash:
md5sum fmodstudio-2.02.18-linux64-240371322.tar.bz2
And you should see something like:
In my case it showed:
acc99f37d58f0285bcaede1da35b3a6a fmodstudio-2.02.18-linux64-240371322.tar.bz2
Now do:
cd ~/src/phoenix-firestorm
Copy the FMOD Studio path and md5 value from the package process into this command:
autobuild installables edit fmodstudio platform=linux64 hash=<md5 value> url=file:///<fmodstudio path>
For example (you would need to type your own info in this section):
autobuild installables edit fmodstudio platform=linux64 hash=acc99f37d58f0285bcaede1da35b3a6a url=file:////home/am/src/3p-fmodstudio/fmodstudio-2.02.18-linux64-240371322.tar.bz2
Configure and build the Viewer:
export AUTOBUILD_VARIABLES_FILE=$HOME/src/fs-build-variables/variables
cd ~/src/phoenix-firestorm
autobuild configure -A 64 -v -c ReleaseFS_open -- --chan="YOURCHANNEL" --package --fmodstudio --no-opensim --avx2 -DLL_TESTS:BOOL=FALSE
At this point you may see some errors downloading 3 or 4 of the libraries due to the wrong “md5 hash” listed in the autobuild.xml.
I think it may be an oversight on the Firestorm devs part but it’s a simple workaround.
Simply download the file it fails the md5 check on from the url shown in terminal and copy it to:
“/var/tmp/am/install.cache/”
(“am” will need to be replaced with the username of yourself on your linux distro)
Repeat the above process for each failed md5 check.
autobuild build -A 64 -v -c ReleaseFS_open -- --chan="YOURCHANNEL" --package --fmodstudio --no-opensim --avx2 -DLL_TESTS:BOOL=FALSE
I use the – -avx2 flag as it’s an optimisation for modern CPUs. If you have an older CPU you may need to remove that build parameter from the configure command.
Also if you plan to use Firestorm Viewer on other “OpenSim” grids then remove the
– -no-opensim flag from the configure/build commands.
If you get an error mentioning “-Werror”, (compiler warning treated as errors), it’s not really a problem and can be bypassed by editing the file: “~/src/phoenix-firestorm/indra/cmake/00-Common.cmake”.
Look for the line: set(GCC_WARNINGS “${GCC_WARNINGS} -Werror”)
and put an # in front of it so it looks like the following and save the file, then it should build without any problems:
After building Firestorm Viewer:
After Firestorm Viewer has finished compiling, it will package it into a file called something like “Phoenix-Firestorm-YOURCHANNEL-6-6-17-70368.tar.xz” which can be found in:
cd ~/src/phoenix-firestorm/build-linux-x86_64/newview/
To extract the file do:
tar -xf Phoenix-Firestorm-YOURCHANNEL-6-6-17-70368.tar.xz
Then:
cd Phoenix-Firestorm-YOURCHANNEL-6-6-17-70368
Firestorm can be run directly from this folder by typing:
./firestorm
Or you can install it on your system by typing:
./install.sh
There are some README files in the Firestorm directory you can read if you want to know more about using Firestorm on Linux or to read about troubleshooting .
It was quite satisfying getting this Viewer build-process to work from a nerdy perspective as I doubt many people have done it (and documented the process.)
Hope this guide of mine helps fellow ArcoLinux (and other Arch-based distro) users to build and use Firestorm without having to rely on that other spy-ridden operating system also known as MS Windows. 😉