Building Synfig Using CMake

The usual process of building with CMake is pretty much the same as the standard one, but despite that, this part will cover that so you can follow along and get the same results.

Below you will find instructions how to build Synfig on various operating systems.

Linux

You need to make a directory where Synfig will be built.

$ mkdir cmake-build && cd cmake-build

Once you’re in your build folder, this is the part where you can configure and set different CMake flags according to your need. For the purpose of this documentation, the default build will be followed.

$ cmake ..

When it completes, you need to build Synfig using make command.

$ make

Once this is complete, you will find the build present in /output folder of your build directory. You can run Synfig by using

$ ./output/bin/synfigstudio

You can also specify a target if you want to build that specific target.

$ make build_images

If you wish to install Synfig to /usr/local/, make sure you have root privileges (or write permissions to those three directories), and simply type

$ make install

OSX

Building on OSX follows the same steps as that of Linux. You need to make a build folder first.

$ mkdir cmake-build && cd cmake-build

Once that’s done, you can run the CMake command along with passing any flags as required.

$ cmake ..

When it completes, you need to build Synfig using make command.

$ make

Once this is complete, you will find the build present in /output folder of your build directory. You can run Synfig by using

$ ./output/bin/synfigstudio

Windows

Synfig is shipped with this special script to build it on Windows (MSYS2). All you need to do is run that script.

$ ./2-build-msys-cmake.sh

Once this is completed successfully, you can run Synfig by.

$ ./cmake-build-msys/output/bin/synfigstudio.exe