2019-05-18 04:22:02 +02:00
|
|
|
{ mkDerivation, lib, stdenv, makeWrapper, fetchurl, cmake, extra-cmake-modules
|
2016-06-01 03:21:56 +02:00
|
|
|
, karchive, kconfig, kwidgetsaddons, kcompletion, kcoreaddons
|
|
|
|
, kguiaddons, ki18n, kitemmodels, kitemviews, kwindowsystem
|
|
|
|
, kio, kcrash
|
2018-07-01 14:09:58 +02:00
|
|
|
, boost, libraw, fftw, eigen, exiv2, libheif, lcms2, gsl, openexr, giflib
|
2018-09-13 07:22:39 +02:00
|
|
|
, openjpeg, opencolorio, vc, poppler, curl, ilmbase
|
2019-05-29 12:46:55 +02:00
|
|
|
, qtmultimedia, qtx11extras, quazip
|
2019-03-12 13:02:16 +01:00
|
|
|
, python3Packages
|
2016-06-01 03:21:56 +02:00
|
|
|
}:
|
|
|
|
|
2017-05-17 21:26:11 +02:00
|
|
|
mkDerivation rec {
|
2019-07-06 01:04:45 +02:00
|
|
|
pname = "krita";
|
2020-07-05 10:17:37 +02:00
|
|
|
version = "4.3.0";
|
2016-06-01 03:21:56 +02:00
|
|
|
|
2016-11-23 15:53:40 +01:00
|
|
|
src = fetchurl {
|
2019-09-11 04:25:41 +02:00
|
|
|
url = "https://download.kde.org/stable/${pname}/${version}/${pname}-${version}.tar.xz";
|
2020-07-05 10:17:37 +02:00
|
|
|
sha256 = "19qlpp9ds60bab73pwi64dq1zn4zn2hcdkrxhjr1j438mc4pflsd";
|
2016-06-01 03:21:56 +02:00
|
|
|
};
|
|
|
|
|
2020-03-30 16:52:50 +02:00
|
|
|
# *somtimes* fails with can't find ui_manager.h, also see https://github.com/NixOS/nixpkgs/issues/35359
|
|
|
|
enableParallelBuilding = false;
|
|
|
|
|
2019-05-18 04:22:02 +02:00
|
|
|
nativeBuildInputs = [ cmake extra-cmake-modules python3Packages.sip makeWrapper ];
|
2016-06-01 03:21:56 +02:00
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
karchive kconfig kwidgetsaddons kcompletion kcoreaddons kguiaddons
|
|
|
|
ki18n kitemmodels kitemviews kwindowsystem kio kcrash
|
2018-07-01 14:09:58 +02:00
|
|
|
boost libraw fftw eigen exiv2 lcms2 gsl openexr libheif giflib
|
2018-09-13 07:22:39 +02:00
|
|
|
openjpeg opencolorio poppler curl ilmbase
|
2019-05-29 12:46:55 +02:00
|
|
|
qtmultimedia qtx11extras quazip
|
2019-03-12 13:02:16 +01:00
|
|
|
python3Packages.pyqt5
|
2018-09-01 20:25:38 +02:00
|
|
|
] ++ lib.optional (stdenv.hostPlatform.isi686 || stdenv.hostPlatform.isx86_64) vc;
|
2016-06-01 03:21:56 +02:00
|
|
|
|
2020-01-11 21:15:12 +01:00
|
|
|
NIX_CFLAGS_COMPILE = [ "-I${ilmbase.dev}/include/OpenEXR" ]
|
|
|
|
++ lib.optional stdenv.cc.isGNU "-Wno-deprecated-copy";
|
2016-06-01 03:21:56 +02:00
|
|
|
|
2019-03-12 13:02:16 +01:00
|
|
|
cmakeFlags = [
|
|
|
|
"-DPYQT5_SIP_DIR=${python3Packages.pyqt5}/share/sip/PyQt5"
|
|
|
|
"-DPYQT_SIP_DIR_OVERRIDE=${python3Packages.pyqt5}/share/sip/PyQt5"
|
|
|
|
"-DCMAKE_BUILD_TYPE=RelWithDebInfo"
|
|
|
|
];
|
|
|
|
|
2019-05-18 04:22:02 +02:00
|
|
|
postInstall = ''
|
|
|
|
for i in $out/bin/*; do
|
|
|
|
wrapProgram $i --prefix PYTHONPATH : "$PYTHONPATH"
|
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
2017-05-17 21:26:11 +02:00
|
|
|
meta = with lib; {
|
2018-03-01 07:36:11 +01:00
|
|
|
description = "A free and open source painting application";
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "https://krita.org/";
|
2016-06-01 03:21:56 +02:00
|
|
|
maintainers = with maintainers; [ abbradar ];
|
|
|
|
platforms = platforms.linux;
|
2017-04-30 13:42:35 +02:00
|
|
|
license = licenses.gpl2;
|
2016-06-01 03:21:56 +02:00
|
|
|
};
|
|
|
|
}
|