To get the latest Blender successfully running on Linux system, follow a few simple steps.
- Download Blender source.
- Install required package dependencies.
- Compile Blender.
2. Install 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), Fedora, Suse and Arch distributions.
When using the
install_deps.sh script, you are only required to install the following dependencies:
sudo apt-get update; sudo apt-get install git build-essential
Then, get the sources and run
cd ~/blender-git ./blender/build_files/build_environment/install_deps.sh
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 (
- Attempt to build main 'big' libraries you cannot easily install from packages (
--helpof the script for details).
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 and SCons you should use to build Blender.
+ install_deps.sh options
This scripts accepts some optional command lines arguments (use
+ Manual Dependency Installation (optional)
Manual Dependency Installation
To manually install Blender's dependancy packages:
sudo apt-get update; sudo apt-get install git build-essential \ libx11-dev libxi-dev \ libsndfile1-dev \ libpng12-dev libjpeg-dev libfftw3-dev \ libopenexr-dev libopenjpeg-dev \ libopenal-dev libalut-dev libvorbis-dev \ libglu1-mesa-dev libsdl1.2-dev libfreetype6-dev \ libtiff5-dev libavdevice-dev \ libavformat-dev libavutil-dev libavcodec-dev libjack-dev \ libswscale-dev libx264-dev libmp3lame-dev python3.4-dev \ libspnav-dev libtheora-dev libglew-dev
As a final note, here are the key libraries that you may want to use with Blender:
See also: Building Dependencies From Source
1. Get the source
The first step is to get the latest Blender source code from blender.org'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 http://git.blender.org/blender.git cd blender git submodule update --init --recursive git submodule foreach git checkout master git submodule foreach git pull --rebase origin master
If you want to update your git clone checkout to the latest source do (in ~/blender-git/blender/):
git pull --rebase git submodule foreach git pull --rebase origin master
For additional information on using Git with Blender's sources, see: Tools/Git
Compile Blender with Scons
Do I need to install Scons?
No, currently scons is embedded in Blenders' source code.
How do I configure Scons?
By default, Scons will pickup the right configuration file depending on your operating system (Linux, Mac, Windows, etc...) and architecture (32/64bit, etc).
In the Blender source (see #Get the source above) these files are located in
aix4-config.py darwin-config.py irix6-config.py linux2-config.py linuxcross-config.py openbsd3-config.py sunos5-config.py win32-mingw-config.py win32-vc-config.py win64-vc-config.py
For example, if you are working on a 32bit machine with Linux, Scons will pickup
linux2-config.py to setup the Blender build.
If all the parameters in that file work for you, just start building Blender (see below).
If you don't have a system Python 3.2 and the package isn't available you may have to build your own and install to a custom location, or you want to build your own FFMPEG, or maybe you don't want to build the Game Engine, or the Blender Player, and so on.
In such a situation, you have to create a file called
If you don't know what to put in
user-config.py, please have a look at Scons default options to see their meaning.
In general, you have to copy some line from the default config file (in our example,
linux2-config.py) and change the parameters that you want to override.
Note: since you intend to use Blender, you probably have a modern multi-core computer, so you should use the parallel build option to speed up the build. If you have a 2-core machine without hyperthreading, append -j 2 to the scons command. If you have a quad-core machine with hyperthreading, append -j 8 to the scons command.
cd ~/blender-git/blender python scons/scons.py
At the end of the build process you will have a blender binary and a message...
Install file: "/home/myname/blender-git/blender/build/linux2/bin/blender" as "/home/myname/blender-git/blender/install/linux2/blender" scons: done building targets. *** Success ***
to run blender from the root path "~/blender-git/blender" you can create a symlink to the binary here... (the following example assumes you want the linux2 version)
cd ~/blender-git/blender ln -s ../install/linux2/blender ./blender
Now you can run by typing (in ~/blender-git/blender)...
Rebuild after changing any files (in ~/blender-git/blender/ )...
If you have a multi-core CPU you can compile with multi-threading using the following:
python scons/scons.py -j 2
The number stands for the number of jobs, so if you have a quad-core CPU you could put "-j 4".
For completeness, please check these scons options.
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 'https://server.com/repo': Certificate verification error: signed using insecure algorithm (https://server.com/repo)
In the [groups] section (before [global]) of your ~/.subversion/servers add the following:
blender = svn.blender.org [blender] ssl-trust-default-ca = no