2019-08-25 03:13:13 +02:00
|
|
|
{ stdenv
|
|
|
|
, fetchurl
|
|
|
|
, fetchpatch
|
|
|
|
, pkgconfig
|
|
|
|
, vala
|
|
|
|
, gobject-introspection
|
|
|
|
, gtk-doc
|
|
|
|
, docbook_xsl
|
|
|
|
, docbook_xml_dtd_43
|
|
|
|
, glib
|
|
|
|
, babl
|
|
|
|
, libpng
|
|
|
|
, cairo
|
|
|
|
, libjpeg
|
|
|
|
, librsvg
|
|
|
|
, lensfun
|
|
|
|
, libspiro
|
|
|
|
, netsurf
|
|
|
|
, pango
|
|
|
|
, poly2tri-c
|
2020-02-21 12:01:06 +01:00
|
|
|
, poppler
|
2019-08-25 03:13:13 +02:00
|
|
|
, bzip2
|
|
|
|
, json-glib
|
|
|
|
, gettext
|
|
|
|
, meson
|
|
|
|
, ninja
|
|
|
|
, libraw
|
|
|
|
, gexiv2
|
|
|
|
, libwebp
|
|
|
|
, luajit
|
|
|
|
, openexr
|
2019-11-03 18:37:39 +01:00
|
|
|
, OpenCL
|
2020-02-11 15:58:33 +01:00
|
|
|
, suitesparse
|
2019-08-25 03:13:13 +02:00
|
|
|
}:
|
2018-04-28 00:59:26 +02:00
|
|
|
|
2019-04-08 14:21:13 +02:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "gegl";
|
2020-02-21 12:01:06 +01:00
|
|
|
version = "0.4.22";
|
2018-04-28 00:59:26 +02:00
|
|
|
|
2018-08-20 15:04:22 +02:00
|
|
|
outputs = [ "out" "dev" "devdoc" ];
|
|
|
|
outputBin = "dev";
|
|
|
|
|
2018-04-28 00:59:26 +02:00
|
|
|
src = fetchurl {
|
2019-08-25 03:13:13 +02:00
|
|
|
url = "https://download.gimp.org/pub/gegl/${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.xz";
|
2020-02-21 12:01:06 +01:00
|
|
|
sha256 = "0q9cckf90fb82qc5d496fjz459f1xw4j4p3rff1f57yivx0yr20q";
|
2018-04-28 00:59:26 +02:00
|
|
|
};
|
|
|
|
|
2019-08-25 03:13:13 +02:00
|
|
|
patches = [
|
2020-01-03 00:01:31 +01:00
|
|
|
# Remove gegl:simple / backend-file test that times out frequently
|
|
|
|
./patches/no-simple-backend-file-test.patch
|
2019-08-25 03:13:13 +02:00
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pkgconfig
|
|
|
|
gettext
|
|
|
|
meson
|
|
|
|
ninja
|
|
|
|
vala
|
|
|
|
gobject-introspection
|
|
|
|
gtk-doc
|
|
|
|
docbook_xsl
|
|
|
|
docbook_xml_dtd_43
|
|
|
|
];
|
2018-04-28 00:59:26 +02:00
|
|
|
|
|
|
|
buildInputs = [
|
2019-08-25 03:13:13 +02:00
|
|
|
libpng
|
|
|
|
cairo
|
|
|
|
libjpeg
|
|
|
|
librsvg
|
|
|
|
lensfun
|
|
|
|
libspiro
|
|
|
|
netsurf.libnsgif
|
|
|
|
pango
|
|
|
|
poly2tri-c
|
2020-02-21 12:01:06 +01:00
|
|
|
poppler
|
2019-08-25 03:13:13 +02:00
|
|
|
bzip2
|
|
|
|
libraw
|
|
|
|
libwebp
|
|
|
|
gexiv2
|
|
|
|
luajit
|
|
|
|
openexr
|
2020-02-11 15:58:33 +01:00
|
|
|
suitesparse
|
2019-11-03 18:37:39 +01:00
|
|
|
] ++ stdenv.lib.optional stdenv.isDarwin OpenCL;
|
2019-08-25 03:13:13 +02:00
|
|
|
|
|
|
|
# for gegl-4.0.pc
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
glib
|
|
|
|
json-glib
|
|
|
|
babl
|
|
|
|
];
|
|
|
|
|
|
|
|
mesonFlags = [
|
|
|
|
"-Ddocs=true"
|
|
|
|
"-Dmrg=disabled" # not sure what that is
|
|
|
|
"-Dsdl2=disabled"
|
|
|
|
"-Dpygobject=disabled"
|
|
|
|
"-Dlibav=disabled"
|
|
|
|
"-Dlibv4l=disabled"
|
|
|
|
"-Dlibv4l2=disabled"
|
2019-12-01 17:02:09 +01:00
|
|
|
# Disabled due to multiple vulnerabilities, see
|
|
|
|
# https://github.com/NixOS/nixpkgs/pull/73586
|
|
|
|
"-Djasper=disabled"
|
2018-04-28 00:59:26 +02:00
|
|
|
];
|
|
|
|
|
2019-08-25 03:13:13 +02:00
|
|
|
# TODO: Fix missing math symbols in gegl seamless clone.
|
|
|
|
# It only appears when we use packaged poly2tri-c instead of vendored one.
|
2019-11-10 02:08:01 +01:00
|
|
|
NIX_CFLAGS_COMPILE = "-lm";
|
2018-04-28 00:59:26 +02:00
|
|
|
|
2019-08-25 03:13:13 +02:00
|
|
|
postPatch = ''
|
|
|
|
chmod +x tests/opencl/opencl_test.sh tests/buffer/buffer-tests-run.sh
|
|
|
|
patchShebangs tests/ff-load-save/tests_ff_load_save.sh tests/opencl/opencl_test.sh tests/buffer/buffer-tests-run.sh tools/xml_insert.sh
|
|
|
|
'';
|
|
|
|
|
2019-11-03 18:37:39 +01:00
|
|
|
# tests fail to connect to the com.apple.fonts daemon in sandboxed mode
|
|
|
|
doCheck = !stdenv.isDarwin;
|
2018-04-28 00:59:26 +02:00
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Graph-based image processing framework";
|
|
|
|
homepage = http://www.gegl.org;
|
|
|
|
license = licenses.gpl3;
|
|
|
|
maintainers = with maintainers; [ jtojnar ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|