illustrator , concept-artist

Building Krita on Linux for cats

Published the 18 november 2013 in Tutorials with tags : Krita, dev, Linux

Translations available :
- Español, by Gerson Alvarado : Lewatoto's blog

Intro :

Almost a year after I released my Compilscripts on GitHub I discovered I made a mistake.
At the root of the project , Compilscript approach is broken by design. So,  I decided to stop support for it

What was Compilscript ? 

Compilscript was a set of scripts to help user to compile and install Krita ( last development version ) and doing maintenance auto-magically. The scripts met a little success. And I'm still proud about all the things I learned while making it.

What's wrong ?

When something irregular happens, Compilscript fail and stop to work  ...  And irregularities are common on Linux.  The user is dependent of a system he doesn't understand. And when it breaks, it breaks his production without letting him know how to fix it. That's not a solution.

A new approach 

That’s why I thought the best new approach is the Arch-way not to give an automatic tool , but creating a documentation dead-easy to make artist independent in the process and understand what they do.
Artists should be able to install, update, go back in the history of code if something doesn’t work for them ; all of this with a minimal and easy to use documentation.

Fully illustrated

I also offer here a set of illustrations about compiling ( all are released under CC-By  ). I hope those picture will help other project's documentation to be more user friendly and appear more simple to understand by using a simple analogy : a cat building a house. 

Why a cat ? 

Because it's well known on the Internet : you can't go wrong with cats. 

Setup directories

First obligatory step : preparing the place. Around 5GB of disk space will be needed on your home folder. We will set the structure advised by developers :
  • /home/<your-user-name>/kde4/src     for the source code.
  • /home/<your-user-name>/kde4/build   where Krita will be built
  • /home/<your-user-name>/kde4/inst  where Krita will be installed

Note : understand <your-user-name> as your user name on this documentation ( Ex :  /home/deevad/kde4/src )

To do it, open a Terminal,  copy the line under (Ctrl+C) then paste it on the Terminal (Ctrl+Shift+V ) :

mkdir -p ~/kde4/src ~/kde4/build ~/kde4/inst

Also check with your distribution package-manager that no calligra and krita packages are installed.

Use the search field of your package manager and remove packages.

Get the source code

Navigate your folder using the command cd ( change directories ) and the tab key for auto-completion.
cd ~/kde4/src

Install git from your distribution package-manager.
Then ask git to grab source files, pasting this line code in the Terminal , on the ~/kde4/src directory :
git clone git://

Get the libraries and dependencies

This part can be tricky : each distribution got a different way to manage packages and so installing required libraries.

Krita as a part of Calligra need a large amount of libraries ; and there is not always a single command to get them.
Some distributions ( Ubuntu , OpenSuse ) got a general meta package for this, but other , not.

Read the official wiki documentation section linked here to get the last code to auto-get the libraries list for your operating system.
 ( Note : this link is a wiki, so don't hesitate to edit, correct, and then smooth the installation process for other artist later. ) 

If your distribution is not listed, let's go plan B and find them one by one on your package manager . it sounds painfull, but it will not take really long.

( Note : Some distributions will get sometime naming convention for libraries <library-name>-dev or <library-name>-devel as package name) .

This list will help you :
git make cmake boost boost-build kdepimlibs eigen kdegraphics-okular 
libgsf libwpd libwpg libwps pstoedit glew gsl automoc4 boost libkdcraw
libpqxx fftw opengtl lcms2 vc exiv2

In rare case, and if your distribution is not recent, it might happen a library provided by your distribution is outdated. You'll need to build this dependencies. Remember , README files and internet search engine are your friends.


Configuring with cmake will check if your system is ready and if you get the good libraries installed. So, if any configuration problem happen you'll be able to read what libraries are missing. That's why it's important to read if all is ok.

Also, we will inform cmake our directories structure, and also ask to build only Krita. But before, a cd to do this at the proper place :
cd ~/kde4/build


After reading the configure output, if all sounds ok , then it's time to build your own Krita.
Still on the folder /kde4/build, call make with -j<number>, where <number> has to be replaced with the number of parallel job your processor is able to do ( and +1 recommended sometime ). Mine is a 8 core, let's use -j9 .
make -j9

Tip : if you don't know the number of core you have, this little command will answer you the number :

cat /proc/cpuinfo | grep processor | wc -l


If make built all the part of Krita without getting a mistake, and till 100% , you can ask make to install it in our install folder.
make install -j9

Path and environment variables

Your install is now done, but your system will not consider your install folder as a part of your system's application.
Let's show to your system the right path, inside a Terminal, copy line by line :
export KDEDIRS=$HOME/kde4/inst:$KDEDIRS
export PATH=$HOME/kde4/inst/bin:$PATH

Unfortunately those environment variable are not persistent, and will be lost after a shutdown or a restart of your system and our bridge will collapse.
To set them at any login , write them with your favorite text editor at the end of your ~/.profile file ( on certain distribution, the profile is named xprofile , check your hidden file in your home/<your-user-name> folder ).

And then you need to register Krita to the system, kbuildsycoca4 does it by executing in a terminal :

First run

Congratulation ! you can run "last-Krita-from-a-minute-ago" by typing krita on a Terminal or via your desktop main menu.
If this one doesn't show Krita, look at your desktop-environment 's documentation : "how to create a custom launcher" .


You've heard of a new feature developed , or you read about an annoying bug fixed, and want to update ?
Fine, call git again . This time it will only append to your source folder the missing code lines. Not downloading the whole source pack.

cd into the source folder, then ask git to pull to update your source :
cd ~/kde4/src/calligra/
git pull

But updating the source will not be sufficient ; to experience your new Krita version, we need to repeat the configure,compile and install process :
cd ~/kde4/build
make -j8
make install -j8

If you update daily, you might like to automatise those command by making your own minimal script. I share mine here on 'KDE paste' service .


Recent development version might break, and sometime be unusable. Experimental changes are made daily.

It might affect your productivity if you don't know how to 'go back in time' ( ex: your favorite brush doesn't work anymore ).

But If you know how to do it, no issue can really affect you, because you know how to come back to a previous state.

To travel the source in time we need to read the timeline history. The Terminal tool for it is git log
cd ~/kde4/src/calligra/
git log

With git log , you can consult all the last changes to the code, named 'commit' . What interrest us is the long identification number ( ex: 15c1749105a7e7cc56b646a66919c29646f8653a ). You can scroll git log , copy the ID number then quit ( letter Q on keyboard ). Then time-travel your source directory :

git checkout 15c1749105a7e7cc56b646a66919c29646f8653a

Now, configure, compile, and you'll be again in a safe place. Note that I advice the packages gitg or gitk to have a graphic user interface to visualise git history. Also an online version exist here .

To update again to the actual and fresh from a minute ago source-code named master , simply ask git to come back to it with git checkout  then  pull to update :

git checkout master
git pull


I hope this documentation will help many user to have good time using Krita development version.
Use the comments to give your feedbacks or ask questions, I'll do my best to update the information on this page.

Useful Links :
- Official Calligra building documentation wiki.
- Calligra Git activities and history
- List of the last updated Krita bugs
- Form to enter a Krita bug
- Old Compilscript repository ( will be deleted soon )
- Krita blog
- Krita forum
- Krita IRC channel  ( answer can arrive sometime after 1 or 2h, be patient )

Special Thanks :
Boudewijn Rempt, Aurélien Gâteau, M.Beast, Yu Asakusa, Matthieu Harel for feedback and help with corrections.
Gerson Alvarado for Spanish translation.

Creative Commons License
This article and illustrations are licensed under a
Creative Commons Attribution 3.0 Unported License



Avatar Gravatar
tuesday 19 november 2013, 05:50

Thanks David, I ended up deleting and uninstalling all packages from your compilescripts and following along this guide. Very nice visualization as well, I enjoy every step as there are cute little kitty accompany my progress. Again thanks a lot.

Avatar Gravatar
tuesday 19 november 2013, 09:05

Totally awesome! I've just got two remarks:

* freetds isn't needed among the dependencies
* git fetch only 'fetches' the changes, it doesn't apply them to your current set of source files. After a 'git fetch' you still need to do a 'git checkout origin master' to update the sources.

Avatar Gravatar

3. Chris

tuesday 19 november 2013, 09:06

I don't need to build Krita but I liked to follow your cat during all the step of building his house :-). All manuals should use artwork like these ;-) to encourage users to read it...

Avatar Gravatar

4. Rabah

tuesday 19 november 2013, 09:49

Merci pour ce Tuto, j'utilise pas Krita mais j'ai adoré tes illustrations.

Avatar Gravatar

5. yy

tuesday 19 november 2013, 11:15

salut David

avez vous créez des tutos pour apprendre à dessiner ? merki :)

Avatar Gravatar

6. Beast

tuesday 19 november 2013, 12:53

As a end user you want "git pull" not "git fetch", pull does all the magic for you, get all the changes and applies them, while leaving your own changes (commits) intact.

Avatar Gravatar
tuesday 19 november 2013, 12:59

Great Job!

Avatar Gravatar

8. cajone

tuesday 19 november 2013, 13:22

David, Awesome document, love the illustrations, one of the best how to docs I have ever seen :), I can see this becoming a sideline ;)

Avatar Gravatar
tuesday 19 november 2013, 13:25

This was a lot of fun to read! I just realized one error in English which might confuse the reader: “if you ignore the number of core you have” → “if you don't know the number of core you have”

Avatar Gravatar

10. Eike Hein

tuesday 19 november 2013, 13:35

Dude, you're amazing! Those illustrations are so much fun.
tuesday 19 november 2013, 13:37

Thanks all for the feedback and also the corrections ( I've added a 'special thanks' part ).
In my effort of simplifications, for sure I made mistakes ( the biggest one was to thought 'git fetch' could be an easier 'git pull' , oh my ... ).
All , should be updated now.

Feel free to point me how to make it better :)

Avatar Gravatar
tuesday 19 november 2013, 14:08

Thanks a lot David for this comprehensive tutorial. I've followed all the steps and finally succeeded in installing Krita with the support for the G'MIC filters. Thus, I'll probably have a look at the source code and play with it.

Avatar Gravatar

13. Michael Tuttle

tuesday 19 november 2013, 16:12

I want to animate this!

Avatar Gravatar

14. xrg

tuesday 19 november 2013, 17:39

Tried building it on Arch and it built correctly but I get some error about Calligra Little CMS not working (liblcms/liblcms2 are both installed if that is what it means). I'll have to mess with it later.

Really nice instructions though. Probably the easiest to follow build instructions I've seen.

Avatar Gravatar
tuesday 19 november 2013, 19:55

A post like this only makes me smile. so fun and easy to follow.

Using git log to search for a checkout is nice, but If marking is important you could add a tag to the version it's working good for you. after you checkout the version you want:

git tag mytag

now to go back to the tagged state do:

git checkout mytag

To update the tag to a newer version. after checkout to the newer version

git tag -f mytag # this updates/overwrites the tag.

A recommended tag could be "stable".

Avatar Gravatar

16. Danni

wednesday 20 november 2013, 20:17

on debian based system the command "sudo apt-get build-dep krita" goes a long way towards downloading and installing the dependencies. Then you only have to worry about new dependencies since the most recent distro version of the application

Avatar Gravatar

17. doozza

friday 22 november 2013, 07:26

I tried multiple times (on a virtual machine) installing Krita on Ubuntu from kde-repos, and it never worked stand-alone: something was always missing. It finally ended up downloading the whole (hude) kde environment (around 1GB) to simply run Krita.
As I can see from your post, you do the same thing with the sources: download everything the KDE offers. But does this manual build only necessary dependencies of Krita, or the Calligra suite, or the KDE environment? I just can't find it in the manual (sorry, maybe I'm simply blind)?

Your manual encourages me to give this sandbox-fun-manual-installation-thingy a new try =) The cats are great. Thank you for such contributions to the community!

Avatar Gravatar
wednesday 27 november 2013, 03:49

this is the best "how-to" that i've seen, many thanks David, i made a translation of this post to spanish, this is the link
wednesday 27 november 2013, 09:30

@doozza : Hey Dooza ; yes, I often end up installing a whole KDE base ; because with Krita-dev the extra package to get don't cost a lot more to grab. With full KDE installed, even if I use Gnome or Xfce ; I can call 'Kde-System-Setting' and tweak a bit the apperance of the oxygen GUI elements .

@lewatoto : Thanks ! translation link added :)
wednesday 27 november 2013, 09:32

@ghevan : Thanks for the tip, I'll use Git Tag on local before upgrade when I'm familiar with a version.

@Michael Tuttle : Animate ? cool ! It's CC-By material, feel free :)

@David Tschumperlé : Super !

Avatar Gravatar
sunday 01 december 2013, 03:03

This is the best description of how cmake works I've ever seen, and entertaining too... it's not even Krita specific, this could obviously be applied to any cmake build system. Genius. You're a legend, Sir David.

Avatar Gravatar
tuesday 17 december 2013, 01:37

Very nice. You are the best.
tuesday 17 december 2013, 08:46

@Olson & @Marcos Nakamine : Thanks !
/me blush

Avatar Gravatar

24. David Gowers

monday 06 january 2014, 23:40

As a longtime programmer / developer, I was frustrated that I couldn't understand how to convince Krita to build (despite building many CMake-based projects in the past). You have resolved this. Thank you :)

As a result, I have implemented some improvements to the experiment brush, the options for winding fill (useful for working with silhouettes) and hard edge.
If you are interested, they are demoed in this image: ; the bug report is . It currently looks like this will get into Krita 2.8.
tuesday 07 january 2014, 09:17

@David Gowers : Wooowww ! your screenshot looks promising.
Yes, I remember to see you around Mypaint. :-)
That's really cool to know my guide could help building Krita .
Have you got an idea of how the 'gradient' ( old feature of Al.chemy ) is done with such a tool ( experimental brush engine ) ?
It's like a Foreground color to Alpha gradient inside the stroke ; ref :

Avatar Gravatar

26. David Gowers

tuesday 07 january 2014, 11:54

I agree with your assessment. When I look at the deviantart link, I suspect the direction of the gradient is also designed to be dependent on where the user started drawing. (lightest near the starting area?)

From my quick assessment of the kis_painter API, it seems like if we want a gradient on a experiment brush shape, we need to change the drawing process from one step to two:
First render the gradient in a temporary buffer, then mask that buffer by the actual shape we are drawing. This all seems quite doable -- the only obstacle is the need to understand how to create the temporary buffer in the correct way.
tuesday 07 january 2014, 12:23

@David Gowers : Oh, I understand about the buffer. It's probably complicating the code a lot ; as it wasn't designed this way. Good to know.

Yes, the gradient use the first point of the stroke and the last too ; and trace the gradient in between them at middle axis , perpendicular ; as I could guess.
But I'm not 100% sure. Ideal would be for me to reinstall Al.Chemy
Here is a graph of my thought :

Avatar Gravatar
tuesday 07 january 2014, 14:56

My cat has something wrong... :)
I tried many times (and with different args in the configuration process (cmake), reading the docs, because I have Qt 4.8.1 that is buggy (but changing args should avoid that problem) and my "qmake -v" says:
QMake version 2.01a
Using Qt version 4.8.1 in /usr/lib/i386-linux-gnu

I have always errors on building process ("make -j3", in my case).
On 7% of the building process I have:

[ 7%] Building CXX object filters/stage/powerpoint/CMakeFiles/ppttoodplib.dir/PptToOdp.cpp.o
CMakeFiles/pigmentcms.dir/compositeops/KoOptimizedCompositeOpFactory.cpp.o: In function `KoReportCurrentArch::ReturnType createOptimizedClass<KoReportCurrentArch>(KoReportCurrentArch::ParamType)':
/home/gabri/Software/kde4/src/calligra/libs/pigment/compositeops/KoVcMultiArchBuildSupport.h:61: undefined reference to `void KoReportCurrentArch::create<(Vc::Implementation)7>(void*)'
CMakeFiles/pigmentcms.dir/compositeops/KoOptimizedCompositeOpFactory.cpp.o: In function `KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpAlphaDarken32>::ReturnType createOptimizedClass<KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpAlphaDarken32> >(KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpAlphaDarken32>::ParamType)':
/home/gabri/Software/kde4/src/calligra/libs/pigment/compositeops/KoVcMultiArchBuildSupport.h:61: undefined reference to `KoCompositeOp* KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpAlphaDarken32>::create<(Vc::Implementation)7>(KoColorSpace const*)'
CMakeFiles/pigmentcms.dir/compositeops/KoOptimizedCompositeOpFactory.cpp.o: In function `KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpOver32>::ReturnType createOptimizedClass<KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpOver32> >(KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpOver32>::ParamType)':
/home/gabri/Software/kde4/src/calligra/libs/pigment/compositeops/KoVcMultiArchBuildSupport.h:61: undefined reference to `KoCompositeOp* KoOptimizedCompositeOpFactoryPerArch<KoOptimizedCompositeOpOver32>::create<(Vc::Implementation)7>(KoColorSpace const*)'
collect2: ld returned 1 exit status
make[2]: *** [lib/] Errore 1
make[1]: *** [libs/pigment/CMakeFiles/pigmentcms.dir/all] Errore 2
make[1]: *** Attesa per i processi non terminati....

And after few lines it stops. If someone had the same problem ..please, let me know ;)

tuesday 07 january 2014, 15:42

@Gabri : Note this morning the source code was broken and couldn't compile. That's why you can read here :
3d6b432 (5 hours ago) Dmitry Kazakov Fix build of calligra/2.8
I wonder if updating your source can't fix it ?
If not, come on the IRC channel to speak to boud and dmitryK about it ; I'm sure there is a flag to build it using other version of Qt, but this is out of my skill .

Avatar Gravatar

30. David Gowers

tuesday 07 january 2014, 22:54

@David Revoy:
I see, the line between the first and final point describes the transparent edge of a plane, and the centre point along that line can be projected towards the most distant edge of the polygon, to find the opaque edge of the plane. Then we know exactly what area the

You'd be right in saying the system is not actually designed for it, but on the other hand, Krita itself does these 'temporary buffer' operations a lot -- this is part of how 'wash' paint application mode operates, there could be no wash mode without temporary buffers. So when I think about it, I can probably use that same buffer.

It is not an 'it's complicated' problem -- making a temporary buffer, then rendering it later to the screen is quite common in image manipulation, and I've done it myself many times.
It's more like a 'language' problem -- I know how to do this task with NumPy, Allegro, SDL, and even just raw C. But I do not know Krita's API, so I do not know how -Krita- expects me to do such an operation. Give me time -- I've only been involved with Krita development for a few days :)

My experience was that it built fine. As it happens, my latest build was after the commit David mentions above, and the previous build was 18-odd commits before that. So it's worth a try. (QT4 4.8.5 and QT5 5.2.0 here, FWIW, on Arch Linux x86_64)

Avatar Gravatar

31. David Gowers

tuesday 07 january 2014, 22:56

* Then we know exactly what area the gradient needs to cover.

Avatar Gravatar

32. David Gowers

tuesday 07 january 2014, 23:10

@David Revoy:

Actually, I already had al.chemy installed, I gave it a go, and it's much simpler, unless there is some customization of the gradient I'm missing:
It simply treats the first point as the 'start point' of the gradient (== full opacity), and the latest point the user has moved to as the 'end point' (full transparency)

It would also be a nice feature if the Krita experiment brush could do what al.chemy does with the fill rule, which is to fill with winding rule by default, then if the user reverses the direction of their drawing, then they begin using non-winding fill (known as 'odd-even rule'). This is a nice balance that lets you both do silhouette work without cutting holes needlessly, and do more complicated abstract shapes if you want.

Avatar Gravatar
wednesday 08 january 2014, 06:44

I need another cat!
wednesday 08 january 2014, 13:34

@David Gowers : Oh nice for your research about the buffer ; it makes sens the 'wash' mode can only use something similar. Also cool you checked what Al.chemy does ; I saw really cool gallery of artist with this feature ( ) No problem for the time ; take as much time as necessary on it, even don't feel forced to do it at all. It's pure bonus ! :-) As far as I know, LukasT wrote the Experimental Brush ; and a lot of enhancement and maintainance was done by DmitryK on it.

@Mery Alison Thompson : Hehe ; mine is 5 month old now and start to be a small adult cat, just a bit crazier :D

Avatar Gravatar
friday 24 january 2014, 12:10

And now David has added that fill rule to krita :-)

Avatar Gravatar

36. julasanakrupan

tuesday 25 february 2014, 05:57

i want to do some brush development in krita,wat i need to do sir?
can you please help me for strat to end for build and all on ubuntu 13.10?
i trying for build from last 10 days but dont know wat happening ???
tuesday 25 february 2014, 10:19

@julasanakrupan : Hi, sorry, but I can't explain it more simplier how to build it than here. Please, recheck all the steps and read carefully. I actually have 13.10 ( ubuntu gnome edition ) and I can compile fine 2.8 ( git checkout origin/calligra/2.8 on the source to restrict them to 2.8 )

Avatar Gravatar
tuesday 01 april 2014, 13:18

The Illustrations are awesomely sweet!
Really good work! ;)

Avatar Gravatar

39. frfrfrfr

thursday 24 april 2014, 23:39

I'm trying to compile, not getting very far. Hitting this:

CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<QVariant>::detach_helper(int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:709: undefined reference to `QListData::detach(int)'
CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<KSharedPtr<KService> >::detach_helper(int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:709: undefined reference to `QListData::detach(int)'
CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<KSharedPtr<KService> >::detach_helper_grow(int, int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:679: undefined reference to `QListData::detach_grow(int*, int)'
CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<QVariant>::detach_helper_grow(int, int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:679: undefined reference to `QListData::detach_grow(int*, int)'
CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<QString>::detach_helper_grow(int, int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:679: undefined reference to `QListData::detach_grow(int*, int)'
CMakeFiles/koplugin.dir/KoPluginLoader.cpp.o: In function `QList<QString>::detach_helper(int)':
/X/tools/rnd/qt/qt_4.8.5/include/QtCore/qlist.h:709: undefined reference to `QListData::detach(int)'
collect2: ld returned 1 exit status
make[2]: *** [lib/] Error 1
make[1]: *** [libs/koplugin/CMakeFiles/koplugin.dir/all] Error 2
make: *** [all] Error 2

I've also seen this:

[ 2%] Built target calligra_shape_text_automoc
make: *** [all] Error 2

I receive a lot of errors in relation to two different versions of QT on the system. I'm using -DQT_QMAKE_EXECUTABLE to specify a different qmake location but I get thrown a TON of warnings about there already being qt libs in /usr/lib64 (older QT version; i'm trying to build on centos 6.2 x64)

I for sure do not have *all* the recommended pre-req's but I have enough that cmake says krita *will* be built.. or is that misleading?

Avatar Gravatar

40. frfrfrfr

friday 25 april 2014, 00:11

Doing some reading, the function it's throwing errors for doesn't exist in the system version of QT i have. Doing a `grep -R` in the build directory shows references to my copy in /usr/lib64/ instead of the version of QT i'm trying to build on.. I DO see references to the correct version, too, so something isn't happening properly when cmake is running perhaps?
friday 25 april 2014, 07:25

@frfrfrfr : Hey frfrfrfr, I think the developpers will be able to help you on the IRC channel #krita on Freenode , or with your browser here : ( be patient, answer depends of who is awake, who can answer ... it can take hours. Here , I'm the only one to receive notifications for this blog. Good luck !

Avatar Gravatar

42. Jussi Pakkanen

sunday 22 june 2014, 15:27

You don't need to run CMake again after doing a git pull. It will do it automatically by itself so you don't have to. The steps needed to update are simply this:

cd into/build/dir
git pull
make -j 9
make install

Avatar Gravatar
friday 11 july 2014, 10:05

We updated the dependencies and now you need eigen3 instead of eigen2.
friday 11 july 2014, 10:41

@Boudewijn Rempt : thx :) I updated the Calligra/build official wiki a week ago about it. I forgot my own page ^__^

Avatar Gravatar

45. Daniel

saturday 26 july 2014, 20:47

Hello, can you help me with krita install or with IRC chat directions?
I use stable (2.8.5) tarball since I have a slow connection atm and when I build it, there's no krita binary anywhere.

As with IRC, I cant see any directions on the page linked in the guide.
sunday 27 july 2014, 09:17

@Daniel : Hi Daniel, my knowledge is limited to the content of this guide, so ; if you meet a problem, I 'm really not sure to can reply. The developpers of Krita on #krita freenode are at the best place to answer you about this; also the forum. It can be a problem of library ( distro ) or a problem with Krita 2.8.5 itself ...

Avatar Gravatar

47. Daniel

sunday 27 july 2014, 17:18

@David REVOY
Thanks for the IRC and .. forums are broken for me.
Unless they allow me to register a usename I want, not usename they made up from my name, they can go scratch their backs with rusty swords.

As for distro problem.. that is indeed the case.
Just a little rant on my side but .. cant it tell that it cant do what I tell it to somewhere at the end of Cmake output, not buried in the log?

-- ---------------- The following required products can NOT be built -----
-- KRITA_APP: Full Krita (for Desktop) [[needed by: KRITA]] | SharedMimeInfo|libeigen2|libexiv2|lcms devel not found

I'll go bother Krita devs about it, because all those are installed.
sunday 27 july 2014, 17:30

@Daniel : mm... A note : I updated in this guide the library for eigen3 ( mandatory for 2.9alpha ). You might just need to hunt manually libeigen2 if you try to build 2.8.5. That can be it.

Avatar Gravatar
thursday 02 october 2014, 22:32

When I get to the cmake step I get the following error:

The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
used as include directory in directory /home/oscar/kde4/build/CMakeFiles/CMakeTmp

Any tips? How do I set this variable? I'm on Ubuntu 14.04
friday 03 october 2014, 09:37

@oscar : Hi Oscar ; sometime it's also happen the development version won't compile ( an error pushed to master happen ). It's not keep in this broken state really long ; and get fixed between 1h and 4h ; try to refresh your sources to update them to match last commit ( ) ; if the problem continue, report on IRC channel ( #krita on freenode ). Good luck !

Avatar Gravatar
friday 05 december 2014, 14:43

Ah, the Ubuntu 14.04 problem... This is because Ubuntu uses Qt5 by default. After installing all dependecies, you need to add the following to the cmake command:


to make sure that cmake finds the right Qt. This is only the case on Ubuntu 14.04 and up.

Avatar Gravatar
friday 05 december 2014, 15:15

Hey, it has come that i had to build krita on opensuse 13.2; there is one thing that i think should be mentioned (propably i have overread it somewhere..) How ever - the prequesite vc must be buildl from src, but not the latest version -> vc will be detected - okay let´s build, but the build fails then... the version that has to be compiled is 0.7.0 (i don´t know if higher or lower version works)

The vc repository could be found on gitorious:

steps to build are:

$ git clone [vc-repository_URL]
$ git checkout 0.7

(-> follow the INSTALL instructions included in the repository files)

$ mkdir build && cd build
$ make -j16
$ make install
(the last one may require root privilegs)

btw the number of cores to use is not so important as long as the option -j[cores] is higher than available cores "make" will simply use all.

If the above is not known it could be hard to figure out whats wrong and vc is not easy to search for in repositories or by searchengines. So, maybe this helps someone reading the comments or you include a hint in your article;

Good luck building, everyone :)
Ah, one last word: the features in 2.9 - holy shit! Amazing! :D

Avatar Gravatar
saturday 20 december 2014, 11:13

Here's my little tutorial on setting up more than one version:

Avatar Gravatar

54. uga

monday 29 december 2014, 14:22

Very great post. I simply stumbled upon your weblog and
wanted to say that I've truly enjoyed browsing your blog posts.
In any case I'll be subscribing for your rss feed and I am hoping
you write once more very soon!

Avatar Gravatar

55. Frank

friday 16 january 2015, 15:06

The illustrations that went along with the doc were great. Makes compile-from-source instructions a lot more interesting (and less intimidating).

Avatar Gravatar

56. Ben

sunday 01 february 2015, 04:14


Great tutorial and nice cat cartoon. I follow the instructions to build krita-2.8.7 (running git checkout calligra/2.8) But somehow kritasketch doesn't get built. Am I missing something?

sunday 01 february 2015, 11:56

@Ben : Hi Ben, I don't have any experience building Kritasketch or Kritagemini. In the official wiki ; ; they advice to get a look to cmake/productsets in the source to get a documentation of the productset available to be built. (eg. -DPRODUCTSET=GEMINI , but the doc says its available only after 2.9 ). In my guide, I write -DPRODUCTSET=KRITA to get only Krita. Maybe -DPRODUCTSET=CREATIVE will be a larger spectrum for 2.8 ? good luck, and don't hesitate to ask on the IRC channel ( #krita on freenode ) , and write back here your solution.

Avatar Gravatar

58. Ben

monday 02 february 2015, 20:03

Hi, Davild,

From Krita's forum
'Sketch and Gemini are broken due to Multiple Documents at the moment. We'll get them back up and running as soon as possible, but for now only desktop works. "

I think I may need kritasketch because on it says under Ubuntu/Mint

sudo apt-get install kritasketch (otherwise you won't have the sketch brush in 2.8.0)

But it seems that sketch brush is already there for krita 2.8.7 without kritasketch


P.S. -DPRODUCTSET=GEMINI returned unknown productset.
monday 02 february 2015, 22:19

@Ben :Hi,

>> Sketch and Gemini are broken due to Multiple Documents at the moment.
yes, in master and 2.9beta branch ; not in 2.8.x branch I guess

>> I think I may need kritasketch because on it says under Ubuntu/Mint
>> sudo apt-get install kritasketch (otherwise you won't have the sketch brush in 2.8.0)
>> But it seems that sketch brush is already there for krita 2.8.7 without kritasketch
Probably, I don't use Krita official package for Mint/Ubuntu. Yes, by the past, the packager of Ubuntu split the 'sketch' brush presets from the Krita package. Probably thinking it's for Kritasketch. I think it was fixed after.

>> P.S. -DPRODUCTSET=GEMINI returned unknown productset.
Sure in 2.8.x branch ; and on 2.9 it's broken.

Avatar Gravatar

60. Darko

sunday 29 march 2015, 13:14

So now I can officially say that day 4 linux noob (me :-)) managed to successfully build my first krita 2.9.1 on linux mint 17.1 (version 14.04 package base).

Thank you David :-)
monday 30 march 2015, 22:41

@Darko : As I said on IRC , I'm impressed ! Bravo!

Avatar Gravatar

62. ~Antonio

tuesday 07 april 2015, 05:51

I'm also experiencing an issue, by which no binary for Krita is installed. As far as I am aware, all dependencies are installed. There are NO error messages produced anywhere in the build process, and this happens whether building with the -DPRODUCTSET=KRITA or -DPRODUCTSET=CREATIVE option. There was, apparently an Ubuntu bug describing a similar issue. It was resolved, however, no one made mention of what the issue was, or how to fix it. So, I just filed it as a new bug in KDE's bug tracker. Hopefully, someone sees it soon. I also encountered a hiccup, where could not be found, when using the CREATIVE option, but was installed just fine with the KRITA option (this only happened once- I tested multiple times, cleaning out the directories before each test attempt). These are very strange bugs.
tuesday 07 april 2015, 17:25

@~Antonio : Thanks for the information ! Here I switched to Antergos, and I use the default package at the moment ( 2.9.1 ). I'll try to test an follow how it works. I'll probably recompile soon ; but the calligra/2.9 branch

Avatar Gravatar

64. ~Antonio

wednesday 08 april 2015, 08:09

Well, I learned something- there were MANY more dependencies I needed (some of which I had to build from source), than are listed, either here or in the KDE build docs. On the surface, this makes sense, as I am running Openbox on Void Linux. What doesn't make sense, however, is that, without those dependiencies, rather than cmake failing and exiting with an error message, for some reason, the folks who make the project figured it was fine for cmake to simply continue. This means being able to also complete a make and install with no error, the result being an install with no binary.

SO, after getting the dependencies sorted out, I am now facing an error on make, and there's no useful information provided to inform me of what's causing it:

CMakeFiles/Makefile2:34463: recipe for target 'libs/pigment/CMakeFiles/pigmentcms.dir/all' failed

Fun stuff. I really would like to give Krita a go, but have to decide, at this point, if it's worth the time I'm putting into building it.
wednesday 08 april 2015, 08:16

@~Antonio : I don't know about the status of the 'master' main git branch since month ; it seams the master trunk became experimental and the stable development all goes into the calligra/2.9 branch ; it was like this in January/february.
To switch to 2.9 ; you need to go into your 'src/calligra' folder ; then call 'git checkout calligra/2.9' . I hope it will work better.

Avatar Gravatar

66. NETHead

saturday 11 april 2015, 17:53

@David Revoy
This doesn't work, same error as ~Antonio here too. I've already switched into 2.9 branch with 'git checkout calligra/2.9' before building.
I'm running LMDE 2 'Betsy' (Linux oberhaus 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt7-1 (2015-03-01) x86_64 GNU/Linux).

Avatar Gravatar

67. NETHead

saturday 11 april 2015, 18:02

Snippet from error log:

libs/pigment/CMakeFiles/pigmentcms.dir/build.make:953: recipe for target 'libs/pigment/CMakeFiles/pigmentcms.dir/KoOptimizedCompositeOpFactoryPerArch_AVX2.cpp.o' failed
make[2]: *** [libs/pigment/CMakeFiles/pigmentcms.dir/KoOptimizedCompositeOpFactoryPerArch_AVX2.cpp.o] Error 1
CMakeFiles/Makefile2:34189: recipe for target 'libs/pigment/CMakeFiles/pigmentcms.dir/all' failed
make[1]: *** [libs/pigment/CMakeFiles/pigmentcms.dir/all] Error 2

Avatar Gravatar

68. NETHead

sunday 12 april 2015, 14:18

@~Antonio, @David Revoy

Playing around, solved it!
It fails due to a wrong version of vc. I simply cloned the git repository and didn't explicitly select branch 0.7 afterwards. For convenience, I've attached a short script to download, build and install the vc library:

#!/usr/bin/env bash


# Prepare directories
mkdir -p ${SOURCE} ${BUILD} ${INSTALL}

# Download source code
git clone ${GITREPO} ${SOURCE}

# Select the right branch (0.7 for calligra)
cd ${SOURCE}
git checkout 0.7

# Build
cd ${BUILD}
make -j`nproc`

# Install
sudo make install
sunday 12 april 2015, 15:24

@NETHead : Oh ! good job ! Too bad to see again the library issue with Krita using an old specific VC version :-/
Thank you for the fast build script and the solution !

Rss feed of the article's comments

Write a Comment

What is the second character in the character chain YGd6q?  :