diff options
author | Robin Gloster <mail@glob.in> | 2016-02-27 00:08:08 +0000 |
---|---|---|
committer | Robin Gloster <mail@glob.in> | 2016-02-27 00:08:08 +0000 |
commit | 3477e662e60ba80a777f9126ba65ca6e9e0fcdf8 (patch) | |
tree | 26aa99e97f980701131668a00a24fcb85c5cd8a8 /pkgs/applications/graphics | |
parent | b4dadff5429d0bf47bcdafff14dd3d0032039699 (diff) | |
parent | 766ad682f146a755b460dd87006912a96d915bcd (diff) | |
download | nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar.gz nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar.bz2 nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar.lz nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar.xz nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.tar.zst nixlib-3477e662e60ba80a777f9126ba65ca6e9e0fcdf8.zip |
Merge remote-tracking branch 'upstream/master' into hardened-stdenv
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r-- | pkgs/applications/graphics/gimp/2.8.nix | 6 | ||||
-rw-r--r-- | pkgs/applications/graphics/gimp/plugins/default.nix | 6 | ||||
-rw-r--r-- | pkgs/applications/graphics/gimp/wrapper.nix | 33 | ||||
-rw-r--r-- | pkgs/applications/graphics/hugin/default.nix | 31 | ||||
-rw-r--r-- | pkgs/applications/graphics/jbrout/default.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/graphics/mcomix/default.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/graphics/mirage/default.nix | 4 | ||||
-rw-r--r-- | pkgs/applications/graphics/sane/backends/git.nix | 6 |
8 files changed, 66 insertions, 28 deletions
diff --git a/pkgs/applications/graphics/gimp/2.8.nix b/pkgs/applications/graphics/gimp/2.8.nix index 96d6dbd52857..55e85fc5ec6b 100644 --- a/pkgs/applications/graphics/gimp/2.8.nix +++ b/pkgs/applications/graphics/gimp/2.8.nix @@ -6,6 +6,12 @@ stdenv.mkDerivation rec { name = "gimp-2.8.16"; + # This declarations for `gimp-with-plugins` wrapper, + # (used for determining $out/lib/gimp/${majorVersion}/ paths) + majorVersion = "2.0"; + targetPluginDir = "$out/lib/gimp/${majorVersion}/plug-ins"; + targetScriptDir = "$out/lib/gimp/${majorVersion}/scripts"; + src = fetchurl { url = "http://download.gimp.org/pub/gimp/v2.8/${name}.tar.bz2"; sha256 = "1dsgazia9hmab8cw3iis7s69dvqyfj5wga7ds7w2q5mms1xqbqwm"; diff --git a/pkgs/applications/graphics/gimp/plugins/default.nix b/pkgs/applications/graphics/gimp/plugins/default.nix index 702911fee744..4084018d1d53 100644 --- a/pkgs/applications/graphics/gimp/plugins/default.nix +++ b/pkgs/applications/graphics/gimp/plugins/default.nix @@ -6,9 +6,7 @@ { pkgs, gimp }: let inherit (pkgs) stdenv fetchurl pkgconfig glib; - targetPluginDir = "$out/${gimp.name}-plugins"; - targetScriptDir = "$out/${gimp.name}-scripts"; - prefix = "plugin-gimp-"; + inherit (gimp) targetPluginDir targetScriptDir; pluginDerivation = a: stdenv.mkDerivation ({ prePhases = "extraLib"; @@ -52,7 +50,7 @@ rec { name = "gap-2.6.0"; buildInputs = [ gimp pkgconfig glib pkgs.intltool gimp.gtk ] ++ gimp.nativeBuildInputs; src = fetchurl { - url = ftp://ftp.gimp.org/pub/gimp/plug-ins/v2.6/gap/gimp-gap-2.6.0.tar.bz2; + url = http://ftp.gimp.org/pub/gimp/plug-ins/v2.6/gap/gimp-gap-2.6.0.tar.bz2; sha256 = "1jic7ixcmsn4kx2cn32nc5087rk6g8xsrz022xy11yfmgvhzb0ql"; }; patchPhase = '' diff --git a/pkgs/applications/graphics/gimp/wrapper.nix b/pkgs/applications/graphics/gimp/wrapper.nix new file mode 100644 index 000000000000..53067dc39c9a --- /dev/null +++ b/pkgs/applications/graphics/gimp/wrapper.nix @@ -0,0 +1,33 @@ +{ stdenv, lib, buildEnv, gimp, makeWrapper, gimpPlugins, plugins ? null}: + +let +allPlugins = lib.filter (pkg: builtins.isAttrs pkg && pkg.type == "derivation") (lib.attrValues gimpPlugins); +selectedPlugins = if plugins == null then allPlugins else plugins; +extraArgs = map (x: x.wrapArgs or "") selectedPlugins; + +drv = buildEnv { + name = "gimp-with-plugins-" + (builtins.parseDrvName gimp.name).version; + + paths = [ gimp ] ++ selectedPlugins; + + postBuild = '' + # TODO: This could be avoided if buildEnv could be forced to create all directories + if [ -L $out/bin ]; then + rm $out/bin + mkdir $out/bin + for i in ${gimp}/bin/*; do + ln -s $i $out/bin + done + fi + for each in gimp-2.8 gimp-console-2.8; do + wrapProgram $out/bin/$each \ + --set GIMP2_PLUGINDIR "$out/lib/gimp/2.0" \ + ${toString extraArgs} + done + set +x + for each in gimp gimp-console; do + ln -sf "$each-2.8" $out/bin/$each + done + ''; + }; +in stdenv.lib.overrideDerivation drv (x : { buildInputs = x.buildInputs ++ [ makeWrapper ]; }) diff --git a/pkgs/applications/graphics/hugin/default.nix b/pkgs/applications/graphics/hugin/default.nix index b11ed1a99df7..97181cb0d1bf 100644 --- a/pkgs/applications/graphics/hugin/default.nix +++ b/pkgs/applications/graphics/hugin/default.nix @@ -1,23 +1,25 @@ -{ stdenv, cmake, fetchurl, gnumake, pkgconfig +{ stdenv, cmake, fetchurl, gnumake, pkgconfig, makeWrapper , boost, gettext, tclap, wxGTK , freeglut, glew, libXi, libXmu, mesa -, autopanosiftc, enblend-enfuse, exiv2, ilmbase, lensfun, libpng, libtiff -, openexr, panotools, perlPackages +, autopanosiftc, enblend-enfuse, exiv2, fftw, ilmbase, lensfun, libpng, libtiff +, openexr, panotools, perlPackages, sqlite, vigra }: stdenv.mkDerivation rec { - name = "hugin-2013.0.0"; + name = "hugin-2015.0.0"; src = fetchurl { url = "mirror://sourceforge/hugin/${name}.tar.bz2"; - sha256 = "1mgbvg09xvf0zcm9jfv5lb65nd292l86ffa23yp4pzm6izaiwkj8"; + sha256 = "1gfblax9rxay8xskz5r8bips4nfh70vkyrb8ksgl6pg91c8krn9c"; }; NIX_CFLAGS_COMPILE = "-I${ilmbase}/include/OpenEXR"; buildInputs = [ boost gettext tclap wxGTK freeglut glew libXi libXmu mesa - exiv2 ilmbase lensfun libtiff libpng openexr panotools + exiv2 fftw ilmbase lensfun libtiff libpng openexr panotools + sqlite vigra + perlPackages.ImageExifTool makeWrapper ]; # disable installation of the python scripting interface @@ -27,22 +29,21 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - # commandline tools needed by the hugin batch processor - # you may have to tell hugin (in the preferences) where these binaries reside - propagatedUserEnvPackages = [ autopanosiftc enblend-enfuse gnumake - perlPackages.ImageExifTool - ]; - postInstall = '' - mkdir -p "$out/nix-support" - echo $propagatedUserEnvPackages > $out/nix-support/propagated-user-env-packages + for p in $out/bin/*; do + wrapProgram "$p" \ + --suffix PATH : ${autopanosiftc}/bin \ + --suffix PATH : ${enblend-enfuse}/bin \ + --suffix PATH : ${gnumake}/bin \ + --suffix PATH : ${perlPackages.ImageExifTool}/bin + done ''; meta = { homepage = http://hugin.sourceforge.net/; description = "Toolkit for stitching photographs and assembling panoramas, together with an easy to use graphical front end"; license = stdenv.lib.licenses.gpl2Plus; - maintainers = with stdenv.lib.maintainers; [viric]; + maintainers = with stdenv.lib.maintainers; [ viric hrdinka ]; platforms = with stdenv.lib.platforms; linux; }; } diff --git a/pkgs/applications/graphics/jbrout/default.nix b/pkgs/applications/graphics/jbrout/default.nix index e37c2c283e47..8d6c15129cb3 100644 --- a/pkgs/applications/graphics/jbrout/default.nix +++ b/pkgs/applications/graphics/jbrout/default.nix @@ -1,6 +1,6 @@ -{ stdenv, fetchsvn, buildPythonPackage, python, pyGtkGlade, makeWrapper, pyexiv2, pythonPackages, fbida, which }: +{ stdenv, fetchsvn, buildPythonApplication, python, pyGtkGlade, makeWrapper, pyexiv2, pythonPackages, fbida, which }: -buildPythonPackage rec { +buildPythonApplication rec { name = "jbrout-${version}"; version = "338"; diff --git a/pkgs/applications/graphics/mcomix/default.nix b/pkgs/applications/graphics/mcomix/default.nix index 069a4bace286..39d17a32eec3 100644 --- a/pkgs/applications/graphics/mcomix/default.nix +++ b/pkgs/applications/graphics/mcomix/default.nix @@ -1,6 +1,6 @@ -{ stdenv, fetchurl, buildPythonPackage, python27Packages }: +{ stdenv, fetchurl, buildPythonApplication, python27Packages }: -buildPythonPackage rec { +buildPythonApplication rec { namePrefix = ""; name = "mcomix-1.01"; diff --git a/pkgs/applications/graphics/mirage/default.nix b/pkgs/applications/graphics/mirage/default.nix index c4b14388d1ba..c3f06544bb4a 100644 --- a/pkgs/applications/graphics/mirage/default.nix +++ b/pkgs/applications/graphics/mirage/default.nix @@ -1,6 +1,6 @@ -{ stdenv, fetchurl, buildPythonPackage, python, pygtk, pillow, libX11, gettext }: +{ stdenv, fetchurl, buildPythonApplication, python, pygtk, pillow, libX11, gettext }: -buildPythonPackage rec { +buildPythonApplication rec { namePrefix = ""; name = "mirage-0.9.5.2"; diff --git a/pkgs/applications/graphics/sane/backends/git.nix b/pkgs/applications/graphics/sane/backends/git.nix index bb5e787ede66..0e4d7ae1b83f 100644 --- a/pkgs/applications/graphics/sane/backends/git.nix +++ b/pkgs/applications/graphics/sane/backends/git.nix @@ -1,10 +1,10 @@ { callPackage, fetchgit, ... } @ args: callPackage ./generic.nix (args // { - version = "2016-01-25"; + version = "2016-02-25"; src = fetchgit { - sha256 = "db1fecd671bd8b3a777138bb4815285b4364ee3ad01ab05424b4aa0c20ed9919"; - rev = "056f590f2d147099554d97a89dd5e0ddfa8d6dda"; + sha256 = "842b1186d38de14221be514a58f77c23d9f83979ea45f846440cf9cbb1f26c1f"; + rev = "c5117ed0f1b522eab10fd2248f140b2acad2a708"; url = "git://alioth.debian.org/git/sane/sane-backends.git"; }; }) |