diff options
author | Jan Tojnar <jtojnar@gmail.com> | 2019-10-31 23:20:09 +0100 |
---|---|---|
committer | Jan Tojnar <jtojnar@gmail.com> | 2019-11-03 14:43:12 +0100 |
commit | 43c3f471b8899eaf55e298f81b8cf79b65c0bf7d (patch) | |
tree | 28e6a64cae12db19a26007d340b900cdd7b96304 /pkgs/applications/graphics/gimp | |
parent | c75c6b588ad37c4f300ee6055938a0b5ab7ee8a7 (diff) |
gimp: format with nixpkgs-format
Diffstat (limited to 'pkgs/applications/graphics/gimp')
-rw-r--r-- | pkgs/applications/graphics/gimp/default.nix | 127 |
1 files changed, 107 insertions, 20 deletions
diff --git a/pkgs/applications/graphics/gimp/default.nix b/pkgs/applications/graphics/gimp/default.nix index ef0348cbee77..3eff5642f11a 100644 --- a/pkgs/applications/graphics/gimp/default.nix +++ b/pkgs/applications/graphics/gimp/default.nix @@ -1,9 +1,50 @@ -{ stdenv, fetchurl, substituteAll, pkgconfig, intltool, babl, gegl, gtk2, glib, gdk-pixbuf, isocodes -, pango, cairo, freetype, fontconfig, lcms, libpng, libjpeg, poppler, poppler_data, libtiff -, libmng, librsvg, libwmf, zlib, libzip, ghostscript, aalib, shared-mime-info -, python2Packages, libexif, gettext, xorg, glib-networking, libmypaint, gexiv2 -, harfbuzz, mypaint-brushes, libwebp, libheif, libgudev, openexr -, AppKit, Cocoa, gtk-mac-integration-gtk2 }: +{ stdenv +, lib +, fetchurl +, substituteAll +, pkgconfig +, intltool +, babl +, gegl +, gtk2 +, glib +, gdk-pixbuf +, isocodes +, pango +, cairo +, freetype +, fontconfig +, lcms +, libpng +, libjpeg +, poppler +, poppler_data +, libtiff +, libmng +, librsvg +, libwmf +, zlib +, libzip +, ghostscript +, aalib +, shared-mime-info +, python2Packages +, libexif +, gettext +, xorg +, glib-networking +, libmypaint +, gexiv2 +, harfbuzz +, mypaint-brushes +, libwebp +, libheif +, libgudev +, openexr +, AppKit +, Cocoa +, gtk-mac-integration-gtk2 +}: let inherit (python2Packages) pygtk wrapPython python; @@ -12,20 +53,66 @@ in stdenv.mkDerivation rec { version = "2.10.14"; src = fetchurl { - url = "http://download.gimp.org/pub/gimp/v${stdenv.lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; + url = "http://download.gimp.org/pub/gimp/v${lib.versions.majorMinor version}/${pname}-${version}.tar.bz2"; sha256 = "0m6wdnfvsxyhimdd4v3351g4r1fklllnbipbwcfym3h7q88hz6yz"; }; - nativeBuildInputs = [ pkgconfig intltool gettext wrapPython ]; - propagatedBuildInputs = [ gegl ]; # needed by gimp-2.0.pc + nativeBuildInputs = [ + pkgconfig + intltool + gettext + wrapPython + ]; + buildInputs = [ - babl gegl gtk2 glib gdk-pixbuf pango cairo gexiv2 harfbuzz isocodes - freetype fontconfig lcms libpng libjpeg poppler poppler_data libtiff openexr - libmng librsvg libwmf zlib libzip ghostscript aalib shared-mime-info libwebp libheif - python pygtk libexif xorg.libXpm glib-networking libmypaint mypaint-brushes - ] ++ stdenv.lib.optionals stdenv.isDarwin [ - AppKit Cocoa gtk-mac-integration-gtk2 - ] ++ stdenv.lib.optionals stdenv.isLinux [ libgudev ]; + babl + gegl + gtk2 + glib + gdk-pixbuf + pango + cairo + gexiv2 + harfbuzz + isocodes + freetype + fontconfig + lcms + libpng + libjpeg + poppler + poppler_data + libtiff + openexr + libmng + librsvg + libwmf + zlib + libzip + ghostscript + aalib + shared-mime-info + libwebp + libheif + python + pygtk + libexif + xorg.libXpm + glib-networking + libmypaint + mypaint-brushes + ] ++ lib.optionals stdenv.isDarwin [ + AppKit + Cocoa + gtk-mac-integration-gtk2 + ] ++ lib.optionals stdenv.isLinux [ + libgudev + ]; + + # needed by gimp-2.0.pc + propagatedBuildInputs = [ + gegl + ]; pythonPath = [ pygtk ]; @@ -48,7 +135,7 @@ in stdenv.mkDerivation rec { postFixup = '' wrapPythonProgramsIn $out/lib/gimp/${passthru.majorVersion}/plug-ins/ - wrapProgram $out/bin/gimp-${stdenv.lib.versions.majorMinor version} \ + wrapProgram $out/bin/gimp-${lib.versions.majorMinor version} \ --prefix PYTHONPATH : "$PYTHONPATH" \ --set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE" ''; @@ -56,7 +143,7 @@ in stdenv.mkDerivation rec { passthru = rec { # The declarations for `gimp-with-plugins` wrapper, # used for determining plug-in installation paths - majorVersion = "${stdenv.lib.versions.major version}.0"; + majorVersion = "${lib.versions.major version}.0"; targetPluginDir = "lib/gimp/${majorVersion}/plug-ins"; targetScriptDir = "lib/gimp/${majorVersion}/scripts"; @@ -76,9 +163,9 @@ in stdenv.mkDerivation rec { enableParallelBuilding = true; - meta = with stdenv.lib; { + meta = with lib; { description = "The GNU Image Manipulation Program"; - homepage = https://www.gimp.org/; + homepage = "https://www.gimp.org/"; maintainers = with maintainers; [ jtojnar ]; license = licenses.gpl3Plus; platforms = platforms.unix; |