From Mumble Wiki
Revision as of 00:40, 18 February 2012 by MKrautz (talk | contribs) (Building Mumble: GitHubify and simplify)
Jump to: navigation, search

Building Guides

This page is one of a set of Building pages/guides for the different OSes with information on building Mumble/Murmur.

BuildingLinux BuildingFreeBSD BuildingOpenBSD BuildingMacOSX BuildingWindows


This guide describes the method to get a fully working and redistributable version of Mumble and Murmur that uses the Cocoa version of Qt 4.

To build Mumble you will need:

Setting up the build environment

Start off by creating a directory to host your new environment. By default, we'll be using $HOME/MumbleBuild, but anything goes. (Just remember to change the script below:)

# C compiler
export CC="clang"
export CXX="clang++"
# Mac OS X SDK stuff
export OSX_SDK="/Applications/"
# Autotools, etc. setup
export OSX_CFLAGS="-isysroot $OSX_SDK -arch x86_64 -mmacosx-version-min=10.6"
export OSX_LDFLAGS="-isysroot $OSX_SDK -Wl,-syslibroot,$OSX_SDK -arch x86_64 -mmacosx-version-min=10.6"
# Mumble stuff
export MUMBLE_PREFIX=$HOME/MumbleBuild
# pkgconfig, PATH, etc.
export PKG_CONFIG_PATH=/usr/lib/pkgconfig/:$MUMBLE_PREFIX/lib/pkgconfig/:$PKG_CONFIG_PATH
export PATH=$MUMBLE_PREFIX/Qt4.8/bin/:$PATH
echo Now in x86-64 MumbleBuild environment

Create a copy of the above script as $HOME/MumbleBuild/env, and remember to source it before continuing your build environment set up:

$ source $HOME/MumbleBuild/env
Now in x86-64 MumbleBuild environment

Installing or building pkg-config

If you have Homebrew, MacPorts or Fink available, you probably already have pkg-config installed. If not, either of those packaging solutions are probably the easiest way of acquiring it.

In case you want to compile it yourself, you'll have to download and unpack pkg-config.

sudo mkdir /usr/lib/pkgconfig (choose a path you like)
export PKG_CONFIG_PATH=/usr/lib/pkgconfig
./configure && make && sudo make install 

To make the path permanent add the following line to your ~/.profile file:

export PKG_CONFIG_PATH=/usr/lib/pkgconfig

Also add a path entry to the pkg-config binary to this file:

export PATH=$PATH:/usr/local/bin

Building OpenSSL

Grab it from The latest version we use is 1.0.0g.

Unpack and build:

./Configure darwin64-x86_64-cc -shared --prefix=$MUMBLE_PREFIX --openssldir=$MUMBLE_PREFIX/openssl
make install

Building libxar

Fetch it via SVN:

svn checkout xar-read-only

And build it. LibXAR seems not to want to read the OS X SDK version of libxml2's headers. Instead, it uses the system headers. Therefore we must override the include path.

We also want libxar to link against our own OpenSSL dylibs, which is why we also add the include path and lib dir for our $MUMBLE_PREFIX.

cd xar-read-only/xar
export CFLAGS="-I$OSX_SDK/usr/include/libxml2 ${CFLAGS} -I${MUMBLE_PREFIX}/include/"
./ --prefix=${MUMBLE_PREFIX}

After the build, it's a good thing to make sure things went as they should. We want the built libxar to be able to run on both Lion and Snow Leopard. Check that it's linking against our own libcrypto, and that it's linking against the 9.0.0 compatibility version of libxml2 (that's the Leopard version).

$ otool -L lib/libxar.1.dylib
    $HOME/MumbleBuild/lib/libcrypto.1.0.0.dylib (compatibility version 1.0.0, current version 1.0.0)
    /usr/lib/libxml2.2.dylib (compatibility version 10.0.0, current version 10.3.0)

When all is well, install it:

make install

Building Qt

Download and unpack Qt:

git clone git://
cd mumble-developers-qt
git branch -t 4.8-mumble origin/4.8-mumble
git checkout 4.8-mumble

Then build it:

unset CFLAGS
export CFLAGS="-I$MUMBLE_PREFIX/include"
export CXXFLAGS="-I$MUMBLE_PREFIX/include"
OPENSSL_LIBS="-L$MUMBLE_PREFIX/lib -lssl -lcrypto" ./configure -no-pch -fast -nomake examples -nomake demos -nomake docs -debug-and-release -arch x86_64 -cocoa -qt-sql-sqlite -no-dbus -no-webkit -no-phonon -no-phonon-backend -no-qt3support -openssl-linked -mysql_config no -sdk $OSX_SDK -prefix $MUMBLE_PREFIX/Qt4.8 -opensource -confirm-license
make install

Installing Qt icns icon engine

Grab it:

git clone git://

Build and install it

cd qt-icns-iconengine
qmake -spec unsupported/macx-clang CONFIG+='release'
cp libqicnsicon.dylib $MUMBLE_PREFIX/Qt4.8/plugins/iconengines/libqicnsicon.dylib
make distclean
qmake -spec unsupported/macx-clang CONFIG+='debug'
cp libqicnsicon.dylib $MUMBLE_PREFIX/Qt4.8/plugins/iconengines/libqicnsicon_debug.dylib

Installing Boost

Grab the latest version of Boost from, as of current writing, that is 1.48.0.

Apply the patch available at

It is advisible to unpack Boost to $MUMBLE_PREFIX/include/, so the Boost headers will be available in $MUMBLE_PREFIX/include/boost-1_48_0/, since Mumble will look for the headers in this place by default.

Building libogg

Grab the latest version (current 1.3.0). Build:

./configure --disable-dependency-tracking --prefix=$MUMBLE_PREFIX
sudo make install

Building libvorbis

Grab the latest version (current 1.3.2). Build:

./configure --disable-dependency-tracking --prefix=$MUMBLE_PREFIX
sudo make install

Building libFLAC

Grab the latest version (currently 1.2.1). Build (x86-64):

./configure --build=x86_64-apple-darwin$(uname -r) --prefix=$MUMBLE_PREFIX
sudo make install

Building libsndfile

Grab the latest version (currently 1.0.25).

Patch with:


./configure --prefix=$MUMBLE_PREFIX --disable-sqlite
make install

Building Protocol Buffers

Grab the latest version of Protocol Buffers from its Google Code project: As of this writing, that is version 2.4.1. Direct link:

Build and install it:

./configure --disable-dependency-tracking --prefix=$MUMBLE_PREFIX
make install

Logitech LCD SDK (optional)

Grab it, install it. Build it:

sudo mkdir -p $MUMBLE_PREFIX/lglcd-sdk/
sudo tar -zxvf /Applications/Logitech/GamePanel\ Software/LCD\ Manager/LCDSDK/LCDSDK.tgz -C $MUMBLE_PREFIX/lglcd-sdk/
sudo chmod -vR +r $MUMBLE_PREFIX/lglcd-sdk/

Building Mumble

Fetch the Mumble source from Git:

git clone --recursive

To build the client, execute:

qmake -recursive -spec unsupported/macx-clang CONFIG+='release no-server'

If everything went well, you should now have a application bundle in the release directory of the root of the source tree.

Distributing Mumble

If you wish to create a proper redistributable Mumble application bundle, please refer to the script in the macx/scripts directory. This will help you clean up your application bundle, include the needed dependencies, resources etc., and create a compressed disk image - ready to redistribute!

The script expects you to be in the root of the source tree. After executing, it will spit out a .dmg of your Mumble build in the release folder.

Please note that the script currently is tuned for creating real redistributable versions of Mumble, and as such only works on universal (x86, ppc) release builds!