Building Blender/Linux/Ubuntu

To get the latest Blender successfully running on Linux system, follow a few simple steps.

  1. Download Blender source.
  2. Install required package dependencies.
  3. Compile Blender.

1. Get the source

The first step is to get the latest Blender source code from's GIT repository.

Copy and paste the following instructions into a terminal window. The following commands create a blender-git folder in your home directory by downloading the latest source code commonly referred to as 'master'. An Internet connection is needed.

mkdir ~/blender-git
cd ~/blender-git
git clone
cd blender
git submodule update --init --recursive
git submodule foreach git checkout master
git submodule foreach git pull --rebase origin master

Once you have followed the steps above and checked out Blender's source code, you will probably want update it to the latest development version periodically.

This can be done with the following command (in ~/blender-git/blender/):

make update

For additional information on using Git with Blender's sources, see: Tools/Git

2. Install/Update the dependencies

Automatic dependencies installation

The preferred way to install dependencies under Linux is now to use the script featured with Blender sources. It currently supports Debian (and derived like ubuntu), Fedora, Suse and Arch distributions. When using the script, you are only required to install the following dependencies:

git, build-essential

Then, get the sources and run

cd ~/blender-git

This script works for Debian/Redhat/SuSE/Arch based distributions, both 32 and 64 bits.

For other distributions, it can:

  • Print the list of all main dependencies needed to build Blender (--show-deps option).
  • Attempt to build main 'big' libraries you cannot easily install from packages (--build-foo options, see --help of the script for details).

Important It might be required to re-run once in a while, as Blender updates its dependencies. You will typically want to try this when you have build errors after updating the sources.

Some commands in this script requires sudo, so you'll be likely be asked for your password.

When the script finishes installing/building all the packages, it'll print which parameters for CMake you should use to build Blender.

This scripts accepts some optional command lines arguments (use --help one to get an exhaustive list), among which:

--source <path>
Where to store downloaded sources for libraries we have to build (defaults to ~/src/blender-deps).
--install <path>
Where to install the libraries we have to build (defaults to /opt/lib).
Include some extra libraries that are by default not considered mandatory (main effect of this one is building OpenCollada).

Manual Dependency Installation

To manually install Blender's dependency packages:

git, build-essential, libx11-dev, libxi-dev, libsndfile1-dev, libopenexr-dev, 
libopenjp2-7-dev-dev-dev, libpng12-dev, libjpeg-dev libopenal-dev, libalut-dev, python3.5-dev, 
libglu1-mesa-dev, libsdl-dev, libfreetype6-dev, libtiff4-dev, 
libavdevice-dev, libavformat-dev, libavutil-dev, libavcodec-dev, libswscale-dev, 
libx264-dev, libxvidcore4-dev, libmp3lame-dev, libspnav-dev, python3.5

As a final note, here are the key libraries that you may want to use with Blender:

Python (3.5)
Needed for interface scripts (building without Python is supported but not meant for general use).
Boost (min 1.49)
Necessary for Cycles, OSL, Audaspace, Internationalization…
OpenColorIO (min 1.0)
Necessary to handle color spaces.
Necessary for Cycles and OSL (min 1.1 in this case).
LLVM (min 3.0)
Necessary for OSL.
Enable custom shaders under Cycles.
FFMPEG or libav (ffmpeg fork)
For handling most video formats/codecs.
OpenVDB (min 3.1)
For caching of smoke simulations.

See also: Building Dependencies From Source

3. Compile Blender with CMake

Installing CMake

Install CMake from your package manager.

Automatic CMake Setup

If you're not interested in manually setting up CMake build directory, configuring, building and installing in separate steps, we provide a convenience makefile in Blender's source directory which sets up CMake for you.

cd ~/blender-git/blender

Once the build finishes you'll get a message like..

Blender successfully built, run from: /home/me/blender-git/build_linux/bin/blender

Updating your local checkout and rebuilding is as simple as:

cd ~/blender-git/blender
make update

There are some pre-defined build targets:

  • make - some are turned off by default because they can be difficult to correctly configure for newer developers and aren't essential to use & develop Blender in most cases.
  • make lite - the quickest way to get a Blender build up & running, can also help to avoid installing a lot of dependencies if you don't need video-codecs, physics-sim & cycles rendering.
  • make full - this makes a complete build with all options enabled, matching the releases on

For a full list of the optional targets type...

make help

If you want to have more control over your build configuration or have multiple build directories for a single source directory. You can follow these steps.

Typically useful for developers, who built frequently.

Preparing CMake's directory

Now you have to choose a location for CMake build files, currently in-source builds in Blender aren't supported.

Out-of-source build

By doing an "out-of-source" build you create a CMake's directory aside from ~/blender-git/blender, for example ~/blender-git/build:

mkdir ~/blender-git/build
cd ~/blender-git/build
cmake ../blender

This will generate makefiles in the build directory (~/blender-git/build).


As said above, in-source-builds where you build blender from the source code directory are not supported.
If CMake finds a CMakeCache.txt in the source code directory, it uses that instead of using ~/blender-git/build/CMakeCache.txt.

If you have tried to do an in-source build, you should remove any CMakeCache.txt from the source code directory before actually running the out-of-source build:

rm ~/blender-git/blender/CMakeCache.txt

Editing CMake Parameters

Note that CMake should detect correct parameters so you shouldn't need change defaults to simply to compile blender, this is only if you want to change defaults, make a debug build, disable features etc,
so you may want to skip this section for now and come back to it later if you want to make adjustments.

You can modify the build parameters in different ways:

  • editing ~/blender-git/build/CMakeCache.txt file in a text editor
  • using cmake-gui if your distro supports it
cmake-gui ../blender
Opens a graphical interface where you can easily change parameters and re-configure things.
  • using ccmake tool, with
ccmake ../blender
Opens a text interface where you can easily change parameters and re-configure things.
  • cmake parameters can also be easily set on the command line, for eg.
cmake ../blender \
    -DCMAKE_INSTALL_PREFIX=/opt/blender \
These commands are exactly those found in ~/blender-git/build/CMakeCache.txt so you can copy commands from there and use them in the command line without running ccmake.

Screenshot from cmake-gui, qt based gui for cmake
Screenshot from ccmake, curse-based gui for cmake

Building Blender

After changes have been done and you have generated the makefiles, you can compile using the make command inside the build directory:

cd ~/blender-git/build
make install

Also notice the install target is used, this will copy scripts and documentation into ~/blender-git/build/bin

For future builds you can simply update the repository and re-run make.

cd ~/blender-git/blender
git pull --rebase
git submodule foreach git pull --rebase origin master
cd ~/blender-git/build
make install


Both portable & system installations are supported.

Portable installation is default where scripts and data files will be copied into the build '~/blender-git/build/bin' directory and can be moved to other systems easily.

Disable WITH_INSTALL_PORTABLE to install into CMAKE_INSTALL_PREFIX which uses a typical Unix FHS layout: bin/, share/blender/, man/ etc. }}

Static Linking

If you want to share your build with others you may want to include libraries with Blender (statically linked libraries).

Listing needed shared libs
You can see all needed shared libraries by running:
objdump -x path/to/blender | grep "NEEDED"

Note: by default, Python is not static. To make it so, You'll have to edit PYTHON_LYBRARY to something like /usr/lib/libpython3.4m.a;/usr/lib/libexpat.a (exact paths depend on your OS).

Static Linking Each Library:

Enable general static linking
Set WITH_STATIC_LIBS to ON, so that CMake will try to make Blender link against static libs, when available. Though not perfect, this should reduce quite nicely needed shared libs.
Set the FFMPEG_LIBRARIES var to full paths of all needed libs (xvid, x264, etc.).
Set (or create) Boost_USE_STATIC_LIBS to true. If you are using boost automatically built by the script, you should not need to do anything else.
But if you are using your own distro's boost package, you most likely will have to set (or create) Boost_USE_ICU to true too (and install the relevant libicu development package), to get Blender linking.

TODO: other libs?

Now that you can build Blender and run Blender, there are changes you can make which greatly increase the speed of build times.

Use one of the CMake configuration editors (ccmake or cmake-gui), see Editing CMake Parameters

For really fast rebuilds you can disable Every option with the WITH_ prefix, except for WITH_PYTHON which is needed for the UI. This speeds up linking and gives a smaller binary.

Remove the files created by make install since they will become stale. However, Blender still needs to be able to find its scripts or you will have a very minimalist looking interface. This can be solved by linking the source directory to your Blender binary path so copying isn't needed and scripts are always up to date.

rm -r ~/blender-git/build/bin/*.*
ln -s ~/blender-git/blender/release ~/blender-git/build/bin/

For convenient access, create this symlink to run blender from the source directory:

 ln -s ~/blender-git/build/bin/blender ~/blender-git/blender/blender.bin

You can add any files created this way to ~/blender-git/blender/.git/info/exclude so they won't count as untracked files for git. Add your local files here, instead of in .gitignore, because .gitignore is also committed and will affect everyone else.

See also


Certificate verification error

If you try to check out your code from a hosted subversion repository, under Ubuntu 10.04 or newer, you may be disappointed to have it fail with the error:

svn: OPTIONS of '':
Certificate verification error: signed using insecure algorithm  (

Here is the work around:

In the [groups] section (before [global]) of your ~/.subversion/servers add the following:

blender =
ssl-trust-default-ca = no