As of revision 46075 of the main Firestorm development repository, the Linden Lab toolchain-update codebase has been merged into Firestorm. This represents a major change in the tools required to build the viewer.

With this change, the viewer and its libraries must be built with Xcode 6, CMake 3, and a metadata-capable version of Linden Lab's autobuild tool. Xcode 6 will only run on OS X 10.9 (Mavericks) or later; the last version to run on Mavericks is 6.2. As of this writing, Xcode 6.3.2 is current; that version only runs on OS X 10.10 (Yosemite).

If you want to build a 64-bit version, you must be at least at revision 46220.

Getting development tools

You will need to install the following tools:

  • Xcode. It's a free download from Apple. If you're using Mavericks, you will need to download Xcode 6.2 from the Apple Developers Connection site. You'll need an Apple ID to sign up for that if you haven't. If you're on Yosemite, you can get Xcode without an ADC login.
    • You will need to install the command line tools. To do this, after you've copied the Xcode application to your Applications folder, open a command line (Terminal, or equivalent) window, and issue the command
      xcode-select --install
  • CMake version 3.
    • Again, you will need to install the command line links. The menu option to do this from within CMake is broken, and has been for several versions. From your command line prompt, issue the following command:
      sudo /Applications/
    • This will launch the CMake application with root permissions. Once you've done that, select Tools→Install for Command Line Use from the CMake menu. When that completes, exit CMake.
  • The latest version of the Mercurial source code management system.
    • Use
      hg clone

      to put it somewhere convenient.

    • Add it to your PATH environment variable. The OS X-approved way to do this is to issue the following two commands:
      sudo ln -s <path/to/the/directory> /usr/local/bin/autobuild
      echo '/usr/local/bin/autobuild/bin' | sudo tee /etc/paths.d/99-autobuild

This will not take effect until the next time you open a Terminal window.

  • The pip Python package installation tool, which is required for the next step. Follow the installation instructions on the pip installation page. You will need to run with sudo.
  • The llbase Python package used by autobuild. Issue this command:
    sudo pip install llbase

Additional third party libraries

If you want to use licensed FMOD Ex or KDU build libraries (they are optional) you have to provide these yourself. If you're building Firestorm as part of the project team, ask for the libraries for fmodex and kdu. Put them into /opt/firestorm .

If you're a community builder, you'll need to build these libraries yourself, then change your autobuild.xml file to point to your own versions, or create a different autobuild.xml with your customizations, and use this with autobuild instead of our default autobuild.xml There are some examples of how to build FMOD Ex on the LL Wiki and opensource-dev mailing list.

We've created a non-KDU build target to make this easier. Everywhere you see “ReleaseFS” below, use “ReleaseFS_open” instead. This will perform the same build, using openjpeg instead of KDU and omitting FMOD Ex.

Available premade firestorm-specific build targets:

ReleaseFS		(includes KDU, FMOD)
ReleaseFS_open		(no KDU, no FMOD)
RelWithDebInfo_open	(no KDU, no FMOD)

To build firestorm:

      autobuild build -c ReleaseFS                        

Other examples:

      autobuild configure -c ReleaseFS                    # basic configuration step, don't build, just configure
      autobuild configure -c ReleaseFS -- --clean         # clean the output area first, then configure
      autobuild configure -c ReleaseFS -- --chan Private-Yourname   # configure with a custom channel
      autobuild build -c ReleaseFS --no-configure               # default quick rebuild
      autobuild build -c ReleaseFS --no-configure -- --clean    # Clean rebuild
      autobuild configure -c ReleaseFS_open --            # configure with no third-party libraries
      autobuild configure -c ReleaseFS_open -- --fmodex   # configure with FMOD Ex but no KDU

Any of the configure options can also be used (and do the same thing) with the build options. Typical LL autobuild configure options should also work, as long as they don't duplicate configuration we are already doing.

Logs: Look for logs in build-darwin-i386/logs.

Output: Look for output in build-darwin-i386/newview/Release

Set up your source code tree

Plan your directory structure ahead of time. If you are going to be producing changes or patches you will be cloning a copy of an unaltered source code tree for every change or patch you make, so you might want to have all this work stored in its own directory. If you are a casual compiler and won't be producing any changes, you can use one directory. For this document, I will assume $HOME/firestorm.

mkdir ~/firestorm
cd ~/firestorm
hg clone

This can take a while. It's a rather large download.

Prepare third party libraries

Most third party libraries needed to build the viewer will be automatically downloaded for you and installed into the build directory within your source tree during compilation. Some need to be manually prepared and are not normally required when using an open source configuration (ReleaseFS_open).

FMOD Ex using autobuild

Note: This typically needs to only be done once since fmodex rarely changes.

  • Enter these commands into the command prompt:
hg clone
cd 3p-fmodex
autobuild build
autobuild package

Near the top of the output you will see the package name written and the md5 hash below it:

wrote /Users/tonya/3p-fmodex/fmodex-44453-darwin-201505171651-r21.tar.bz2
md5 3b0d38f2a17ff1b73c8ab6dffbd661eb

Next, update Firestorms autobuild.xml file to use your FMOD Ex.

cd ~/firestorm/phoenix-firestorm-lgpl
cp autobuild.xml my_autobuild.xml
export AUTOBUILD_CONFIG_FILE=my_autobuild.xml

Copy the fmodex path and md5 value from the package process into this command:

autobuild installables edit fmodex platform=darwin hash=<md5 value> url=file:///<fmod path>

For example:

autobuild installables edit fmodex platform=darwin hash=3b0d38f2a17ff1b73c8ab6dffbd661eb url=file:///Users/tonya/3p-fmodex/fmodex-44453-darwin-201505171651-r21.tar.bz2

Note: Having to copy autobuild.xml and modify the copy from within a cloned repository is a lot of work for every repository you make, but this is the only way to guarantee you pick up upstream changes to autobuild.xml and do not send up a modified autobuild.xml when you do an hg push.

Configuring the Viewer

If you are building with FMOD Ex and have followed the previous FMOD Ex setup instructions AND you are now using a new terminal you will need to reset the environment variable with

export AUTOBUILD_CONFIG_FILE=my_autobuild.xml


cd ~/firestorm/phoenix-firestorm-lgpl

 autobuild configure -c ReleaseFS_open

This will compile with all defaults and without third party libraries.

Configuration Switches

There are a number of switches you can use to modify the configuration process. The name of each switch is followed by its type and then by the value you want to set.

  • FMODEX (bool) controls if the FMOD Ex package is incorporated into the viewer. You must have performed the FMOD Ex installation steps in Fmod_using_autobuild for this to work. This is the switch the –fmodex build argument sets.
  • LL_TESTS (bool) controls if the tests are compiled and run. There are quite a lot of them so excluding them is recommended unless you have some reason to need one or more of them.

TIP: OFF and NO are the same as FALSE; anything else is considered to be TRUE


autobuild configure -c ReleaseFS_open -- -DLL_TESTS:BOOL=FALSE -DFMOD:BOOL=TRUE

There is one other switch you can set. The -m64 switch tells autobuild to build a 64-bit version of the viewer. Unlike the others, this one goes before the build or configure argument, as in

autobuild -m64 configure -c ReleaseFS_open

It must be specified on both the configure and build commands. If you want to build a 64-bit viewer after building for 32 bits, or vice versa, you must do the first build when you change the architecture with –clean; otherwise, the viewer may build, but will almost certainly refuse to run.

Compiling the Viewer

If you are building with FMOD Ex and have followed the previous FMOD Ex setup instructions AND you are now using a new terminal you will need to reset the environment variable with

export AUTOBUILD_CONFIG_FILE=my_autobuild.xml


cd ~/firestorm/phoenix-firestorm-lgpl
autobuild build -c ReleaseFS_open --no-configure

Now, sit back, read War and Peace, calculate π to 50 places, tour the country, whatever you desire. Compiling may take quite a bit of time, depending on how fast your machine is and how much else you're doing.

NOTE: It is possible to use autobuild to do both the configure step (only needed once) and the build step with one command (autobuild build -c ReleaseFS [– config options] .) Some find it is clearer if these steps are done separately, but can save a bit of time if done together.

Article Credits

  • Kittin Ninetails
  • Cinder Biscuits
  • Reworked for the toolchain update by Tonya Souther
  • fs_compiling_firestorm_mac_toolchain_update.txt
  • Last modified: 2015/05/21 18:22
  • by tonya