Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
|
05-15-2021, 09:34 AM
|
#1
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Rep:
|
Compile Krita
Allo all,
I am trying to compile Krita.
I followed the instructions at
https://docs.krita.org/en/untranslat...ing_krita.html
I ran
cmake ../krita \
-DCMAKE_INSTALL_PREFIX=$HOME/kritadev/install \
-DCMAKE_BUILD_TYPE=Debug \
-DKRITA_DEVS=ON
and I get
Code:
-- Found KF5Config: /usr/lib/x86_64-linux-gnu/cmake/KF5Config/KF5ConfigConfig.cmake (found version "5.74.0")
-- Could NOT find KF5WidgetsAddons (missing: KF5WidgetsAddons_DIR)
-- Could NOT find KF5WidgetsAddons: found neither KF5WidgetsAddonsConfig.cmake nor kf5widgetsaddons-config.cmake
-- Could NOT find KF5Completion (missing: KF5Completion_DIR)
-- Could NOT find KF5Completion: found neither KF5CompletionConfig.cmake nor kf5completion-config.cmake
-- Found KF5CoreAddons: /usr/lib/x86_64-linux-gnu/cmake/KF5CoreAddons/KF5CoreAddonsConfig.cmake (found version "5.74.0")
What is that?
|
|
|
05-15-2021, 10:43 AM
|
#2
|
LQ Guru
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS, Manjaro
Posts: 5,929
|
If you ar running any version of *Buntu (or Manjaro, or Fedora, or Debian, or ...) then Krita i in oneof your repositories and you should not be compiling it from source. Why can you not using your package manager? What version//release of what distribution are you running?
|
|
|
05-15-2021, 11:01 AM
|
#3
|
Senior Member
Registered: Mar 2020
Posts: 3,706
Rep:
|
Have you installed all the build dependencies listed there? Like libkf5widgetsaddons-dev and libkf5completion-dev?
Even if you're building from source, it's much easier to rebuild from your distro sources than build from scratch. You do know about apt-get source and apt-get build-dep, don't you?
Last edited by shruggy; 05-15-2021 at 11:04 AM.
|
|
|
05-15-2021, 06:36 PM
|
#4
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Original Poster
Rep:
|
Quote:
Originally Posted by wpeckham
If you are running any version of *Buntu (or Manjaro, or Fedora, or Debian, or ...) then Krita is in one of your repositories and you should not be compiling it from source. Why can you not using your package manager? What version//release of what distribution are you running?
|
I am running Kubuntu 20.10. Yes, Krita is in Discover.
But the goal here is to see how to compile Krita and to modify something in Krita and to figure out where to place the executable.
|
|
|
05-16-2021, 05:25 AM
|
#5
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519
|
Compile Krita
Getting all ~69 build dependencies installed :
Code:
sudo apt-get build-dep krita
"build-dep list" https://packages.ubuntu.com/source/groovy/krita
→ → Other Packages Related to krita
-
Last edited by knudfl; 05-16-2021 at 02:13 PM.
|
|
2 members found this post helpful.
|
05-16-2021, 10:51 AM
|
#6
|
LQ Guru
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS, Manjaro
Posts: 5,929
|
Quote:
Originally Posted by vmelkon
I am running Kubuntu 20.10. Yes, Krita is in Discover.
But the goal here is to see how to compile Krita and to modify something in Krita and to figure out where to place the executable.
|
In general, the build process install has install locations specified. You can change them, and if you code enough to modify the package you should already know hoe to find and change the install base.
Best of luck, I think with the install of the prerequisites for the build you are on the right track.
|
|
|
06-09-2021, 11:51 PM
|
#7
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Original Poster
Rep:
|
Quote:
Originally Posted by knudfl
|
It says
jake@john-desktop90:~$ sudo apt-get build-dep krita
[sudo] password for jake:
Reading package lists... Done
E: Unable to find a source package for krita
|
|
|
06-10-2021, 12:49 AM
|
#8
|
Senior Member
Registered: Mar 2020
Posts: 3,706
Rep:
|
Do you have deb-src lines enabled in your /etc/apt/sources.list?
|
|
2 members found this post helpful.
|
06-10-2021, 07:22 PM
|
#9
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Original Poster
Rep:
|
Now I get
Code:
-- Krita version: 5.0.0-prealpha
-- Branding selected: Next
-- Python system site-packages directory: /usr/lib/python3/dist-packages
Installing in /home/jake/kritadev/install. Run /home/jake/kritadev/build/prefix.sh to set the environment for krita.
-- Could NOT find ZLIB (missing: ZLIB_INCLUDE_DIR)
CMake Error at /usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:146 (message):
Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
Call Stack (most recent call first):
/usr/share/cmake-3.16/Modules/FindPackageHandleStandardArgs.cmake:393 (_FPHSA_FAILURE_MESSAGE)
/usr/share/cmake-3.16/Modules/FindPNG.cmake:146 (find_package_handle_standard_args)
CMakeLists.txt:620 (find_package)
but I already ran
sudo apt install zlib1g-dev
sudo apt install libpng-dev
|
|
|
06-11-2021, 12:49 AM
|
#10
|
Senior Member
Registered: Mar 2020
Posts: 3,706
Rep:
|
Well, the problem is only with finding ZLib. CMake fails to find libpng because of the first error. From /usr/share/cmake-3.16/Modules.FindPNG.cmake:
Quote:
The following variables may also be set, for backwards compatibility:
``PNG_LIBRARY``
where to find the PNG library.
``PNG_INCLUDE_DIR``
where to find the PNG headers (same as PNG_INCLUDE_DIRS)
Since PNG depends on the ZLib compression library, none of the above
will be defined unless ZLib can be found.
|
I guess CMakeLists.txt of Krita changed recently, and now breaks builds with CMake 3.16.
Last edited by shruggy; 06-11-2021 at 02:25 AM.
|
|
1 members found this post helpful.
|
06-11-2021, 04:56 AM
|
#11
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519
|
Required deb-src lines in /etc/apt/sources.list lines are ....
... Then there shouldn't be any missing 'build prerequisites' :
Code:
sudo apt update
sudo apt build-dep krita
cd krita/ && mkdir build && cd build/
cmake ..
.. and the cmake configuration is perfect, no errors : Ubuntu 20.04 .
EDIT : Ubuntu 20.04
$ make
[100%] Linking CXX executable krita
[100%] Built target krita
EDIT 1:
Krita 5.0.0-prealpha https://github.com/KDE/krita configures OK with cmake in Ubuntu 20.10 :
--Build files have been written to ~/tmp/krita/build
EDIT 2:
$ sudo apt install libmypaint-dev (One of the optional build packages for 5.0.0).
Your cmake options : $ cmake -DCMAKE_BUILD_TYPE=Debug -DKRITA_DEVS=ON ../
Also OK. --Build files have been written to ~/tmp/krita/build
-
Last edited by knudfl; 06-11-2021 at 10:05 AM.
|
|
1 members found this post helpful.
|
06-11-2021, 01:37 PM
|
#12
|
LQ 5k Club
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,519
|
Compiling with "BUILD_TYPE=Debug" will require 9-10 GB build space, and take some hours to do.
Krita 5.0.0-prealpha, Ubuntu 20.10 :
Code:
$ make
[100%] Linking CXX executable krita
[100%] Built target krita
|
|
1 members found this post helpful.
|
06-11-2021, 06:49 PM
|
#13
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Original Poster
Rep:
|
Quote:
Originally Posted by knudfl
Compiling with "BUILD_TYPE=Debug" will require 9-10 GB build space, and take some hours to do.
Krita 5.0.0-prealpha, Ubuntu 20.10 :
Code:
$ make
[100%] Linking CXX executable krita
[100%] Built target krita
|
Holy smokes!
My krtia folder that I downloaded has 11,250 fiels and 810 folders and it is 932 MB. People typed that much code?
|
|
|
06-11-2021, 07:00 PM
|
#14
|
Member
Registered: Feb 2007
Location: Canada
Distribution: Kubuntu 22.04
Posts: 569
Original Poster
Rep:
|
Quote:
Originally Posted by knudfl
Required deb-src lines in /etc/apt/sources.list lines are ....
... Then there shouldn't be any missing 'build prerequisites' :
Code:
sudo apt update
sudo apt build-dep krita
cd krita/ && mkdir build && cd build/
cmake ..
.. and the cmake configuration is perfect, no errors : Ubuntu 20.04 .
EDIT : Ubuntu 20.04
$ make
[100%] Linking CXX executable krita
[100%] Built target krita
EDIT 1:
Krita 5.0.0-prealpha https://github.com/KDE/krita configures OK with cmake in Ubuntu 20.10 :
--Build files have been written to ~/tmp/krita/build
EDIT 2:
$ sudo apt install libmypaint-dev (One of the optional build packages for 5.0.0).
Your cmake options : $ cmake -DCMAKE_BUILD_TYPE=Debug -DKRITA_DEVS=ON ../
Also OK. --Build files have been written to ~/tmp/krita/build
-
|
But are those lines
deb-src http://archive.ubuntu.com/ubuntu/ groovy main universe
deb-src http://archive.ubuntu.com/ubuntu/ groovy-updates main universe
suppose to exist in that sources.list file or do I have to type them in?
I don't have those lines. Mine looks like
Code:
# deb cdrom:[Kubuntu 20.10 _Groovy Gorilla_ - Release amd64 (20201022)]/ groovy main multiverse restricted universe
# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://ca.archive.ubuntu.com/ubuntu/ groovy main restricted
deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy multiverse restricted universe main
## Major bug fix updates produced after the final release of the
## distribution.
deb http://ca.archive.ubuntu.com/ubuntu/ groovy-updates main restricted
deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy-updates multiverse restricted universe main
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://ca.archive.ubuntu.com/ubuntu/ groovy universe
# deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy universe
deb http://ca.archive.ubuntu.com/ubuntu/ groovy-updates universe
# deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy-updates universe
## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
deb http://ca.archive.ubuntu.com/ubuntu/ groovy multiverse
# deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy multiverse
deb http://ca.archive.ubuntu.com/ubuntu/ groovy-updates multiverse
# deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy-updates multiverse
## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://ca.archive.ubuntu.com/ubuntu/ groovy-backports main restricted universe multiverse
deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy-backports main restricted universe multiverse
## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
deb http://archive.canonical.com/ubuntu groovy partner
# deb-src http://archive.canonical.com/ubuntu groovy partner
deb http://security.ubuntu.com/ubuntu groovy-security main restricted
deb-src http://security.ubuntu.com/ubuntu groovy-security multiverse restricted universe main
deb http://security.ubuntu.com/ubuntu groovy-security universe
# deb-src http://security.ubuntu.com/ubuntu groovy-security universe
deb http://security.ubuntu.com/ubuntu groovy-security multiverse
# deb-src http://security.ubuntu.com/ubuntu groovy-security multiverse
So I added these lines at the bottom
#I added these for krita
deb-src http://archive.ubuntu.com/ubuntu groovy main universe
deb-src http://archive.ubuntu.com/ubuntu groovy-updates main universe
and ran
sudo apt-get build-dep krita
and I guess it did nothing and it says
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
|
|
|
06-12-2021, 03:33 AM
|
#15
|
Senior Member
Registered: Mar 2020
Posts: 3,706
Rep:
|
Quote:
Originally Posted by vmelkon
|
These are equivalent as they include both main and universe components:
Code:
deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy multiverse restricted universe main
[...]
deb-src http://ca.archive.ubuntu.com/ubuntu/ groovy-updates multiverse restricted universe main
|
|
|
All times are GMT -5. The time now is 12:24 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|