From BlenderWiki

Jump to: navigation, search

Building Cycles

For a build with CPU rendering support, see the Building Blender documentation.


Download the CUDA Toolkit 6.5 and install it. Make sure you have recent enough nvidia drivers (e.g. 340.X or newer).

For more details, see GPU rendering in the manual.

Bundling Binary Kernels

CUDA is enabled by default on Linux and Mac, however this will require the machine running Blender to have the CUDA toolkit installed. On Windows kernels need to be bundled with Blender, for that these cmake options must be set:

  • CYCLES_CUDA_BINARIES_ARCH=<arch> (optional, e.g. sm_21)

Or these scons options:

  • BF_CYCLES_CUDA_NVCC = "c:/path/to/nvcc.exe"
  • BF_CYCLES_CUDA_BINARIES_ARCH = ("sm_#",) -- optional, where "sm_#" is the appropriate architecture for your card.

Building CUDA kernels is slow, it may take a few minutes per CUDA architecture, and multithreaded builds can run out of memory. It will compile for all architectures by default, but it's quickest to specify only a single binary arch for your card, look here for the number (sm_# is the same as "Compute Capability" without the '.')

Open Shading Language

To enable OSL, simply set the following cmake option:


You will need to have OSL installed; on Linux the easiest way is by running the script with the argument "--with-osl". Once you install OSL, you will then need to set the following cmake option so cmake will know where to find it:

  • CYCLES_OSL=/opt/lib/osl

You may also need to set these cmake options if they are not set automatically:

  • OSL_COMPILER=/opt/lib/osl/bin/oslc
  • OSL_INCLUDES=/opt/lib/osl/include
  • OSL_LIB_COMP=/opt/lib/osl/lib/liboslcomp.a
  • OSL_LIB_EXEC=/opt/lib/osl/lib/liboslexec.a
  • OSL_LIB_QUERY=/opt/lib/osl/lib/liboslquery.a