about summary refs log tree commit diff
path: root/pkgs/applications/graphics
diff options
context:
space:
mode:
authorVladimír Čunát <vcunat@gmail.com>2016-04-01 10:06:01 +0200
committerVladimír Čunát <vcunat@gmail.com>2016-04-01 10:06:01 +0200
commitab15a62c68bf7bf3b02e3bab00d121cc1426733c (patch)
tree398a82403b04bfa0bae8cadf1c5a64cf83145965 /pkgs/applications/graphics
parentc643ccaa8c91f78b8c89eb87589886b8906d5b38 (diff)
parenta26357eefe017964448b5bb464163646b927a267 (diff)
downloadnixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.gz
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.bz2
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.lz
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.xz
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.tar.zst
nixlib-ab15a62c68bf7bf3b02e3bab00d121cc1426733c.zip
Merge branch 'master' into closure-size
Beware that stdenv doesn't build. It seems something more will be needed
than just resolution of merge conflicts.
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r--pkgs/applications/graphics/antimony/default.nix11
-rw-r--r--pkgs/applications/graphics/darktable/default.nix6
-rw-r--r--pkgs/applications/graphics/digikam/default.nix224
-rw-r--r--pkgs/applications/graphics/giv/build.patch27
-rw-r--r--pkgs/applications/graphics/giv/default.nix12
-rw-r--r--pkgs/applications/graphics/hugin/default.nix4
-rw-r--r--pkgs/applications/graphics/leocad/default.nix5
-rw-r--r--pkgs/applications/graphics/openimageio/default.nix4
-rw-r--r--pkgs/applications/graphics/pencil/default.nix4
-rw-r--r--pkgs/applications/graphics/phototonic/default.nix6
-rw-r--r--pkgs/applications/graphics/sane/backends/git.nix6
-rw-r--r--pkgs/applications/graphics/simple-scan/default.nix8
-rw-r--r--pkgs/applications/graphics/wings/default.nix19
13 files changed, 256 insertions, 80 deletions
diff --git a/pkgs/applications/graphics/antimony/default.nix b/pkgs/applications/graphics/antimony/default.nix
index 5e8dfd93f30e..dded423652ce 100644
--- a/pkgs/applications/graphics/antimony/default.nix
+++ b/pkgs/applications/graphics/antimony/default.nix
@@ -16,6 +16,15 @@ in
     };
 
     patches = [ ./paths-fix.patch ];
+    # fix build with glibc-2.23
+    postPatch = ''
+      sed 's/\<isinf(/std::isinf(/g' -i \
+        src/export/export_heightmap.cpp \
+        src/fab/types/bounds.cpp \
+        src/graph/hooks/meta.cpp \
+        src/ui/dialogs/resolution_dialog.cpp \
+        src/render/render_task.cpp
+    '';
 
     buildInputs = [
       libpng python3 (boost.override { python = python3; })
@@ -32,6 +41,8 @@ in
       qmake antimony.pro PREFIX=$out
     '';
 
+    enableParallelBuilding = true;
+
     meta = with stdenv.lib; {
       description = "A computer-aided design (CAD) tool from a parallel universe";
       homepage    = "https://github.com/mkeeter/antimony";
diff --git a/pkgs/applications/graphics/darktable/default.nix b/pkgs/applications/graphics/darktable/default.nix
index ef222d2e816f..d0a1f7b78d3b 100644
--- a/pkgs/applications/graphics/darktable/default.nix
+++ b/pkgs/applications/graphics/darktable/default.nix
@@ -11,12 +11,12 @@
 assert stdenv ? glibc;
 
 stdenv.mkDerivation rec {
-  version = "2.0.0";
+  version = "2.0.2";
   name = "darktable-${version}";
 
   src = fetchurl {
     url = "https://github.com/darktable-org/darktable/releases/download/release-${version}/darktable-${version}.tar.xz";
-    sha256 = "1cbwvzqn3158cy7r499rdwipx7fpb30lrrvh6jy5a4xvpcjzbwnl";
+    sha256 = "0014j73sy956xqdhd4jrxvbamildqqadx8hmagrbiah8xda67skm";
   };
 
   buildInputs =
@@ -35,7 +35,7 @@ stdenv.mkDerivation rec {
 
   meta = with stdenv.lib; {
     description = "Virtual lighttable and darkroom for photographers";
-    homepage = http://www.darktable.org;
+    homepage = https://www.darktable.org;
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
     maintainers = [ maintainers.goibhniu maintainers.rickynils maintainers.flosse ];
diff --git a/pkgs/applications/graphics/digikam/default.nix b/pkgs/applications/graphics/digikam/default.nix
index bc3678811a5b..119125066bda 100644
--- a/pkgs/applications/graphics/digikam/default.nix
+++ b/pkgs/applications/graphics/digikam/default.nix
@@ -3,42 +3,222 @@
 , libgphoto2, libjpeg, libkdcraw, libkexiv2, libkipi, libpgf, libtiff
 , libusb1, liblqr1, marble, mysql, opencv, perl, phonon, pkgconfig
 , qca2, qimageblitz, qjson, qt4, soprano
+
+# Optional build time dependencies
+, baloo, doxygen, kfilemetadata
+, lcms2
+, kfaceSupport ? true, libkface ? null
+, kgeomapSupport ? true, libkgeomap ? null
+, libxslt
+
+# Plugins optional build time dependencies
+, gdk_pixbuf, imagemagick
+, libgpod, libksane, libkvkontakte
+, qt_gstreamer1 /*qt_soap, <https://github.com/commontk/QtSOAP>  herqq <http://www.herqq.org> -> is missing its av part.*/
+  /*qt_koauth <http://gitorious.org/kqoauth>*/
+
+# Supplementary packages required only by the wrapper.
+, bash, kde_runtime, kde_baseapps, makeWrapper, oxygen_icons
+, phonon_backend_vlc /*phonon_backend_gstreamer,*/
+, ffmpegthumbs /*mplayerthumbs*/
+, runCommand, shared_mime_info, writeScriptBin
 }:
 
-stdenv.mkDerivation rec {
-  name = "digikam-4.12.0";
+let 
+  version = "4.12.0";
+  pName = "digikam-${version}";
+
+  build = stdenv.mkDerivation rec {
+    name = "digikam-build-${version}";
+
+    src = fetchurl {
+      url = "http://download.kde.org/stable/digikam/${pName}.tar.bz2";
+      sha256 = "081ldsaf3frf5khznjd3sxkjmi4dyp6w6nqnc2a0agkk0kxkl10m";
+    };
+
+    nativeBuildInputs = [ 
+      automoc4 cmake gettext perl pkgconfig
+    ] ++ [
+      # Optional
+      doxygen 
+    ];
+
+    buildInputs = [
+      boost eigen jasper kdelibs kdepimlibs lcms lensfun
+      libgphoto2 libjpeg libkdcraw libkexiv2 libkipi liblqr1 libpgf
+      libtiff marble mysql.lib opencv phonon qca2 qimageblitz qjson qt4
+      shared_desktop_ontologies soprano ]
+    # Optional build time dependencies
+    ++ [
+      baloo 
+      kfilemetadata 
+      lcms2 ] 
+    ++ stdenv.lib.optional (kfaceSupport && null != libkface) [ libkface ]
+    ++ stdenv.lib.optional (kgeomapSupport && null != libkgeomap) [ libkgeomap ] ++ 
+    [ libxslt ]
+    # Plugins optional build time dependencies
+    ++ [
+      gdk_pixbuf imagemagick libgpod libksane
+      libkvkontakte
+      qt_gstreamer1 ];
+
+    # Make digikam find some FindXXXX.cmake
+    KDEDIRS="${marble}:${qjson}";
+
+    # Find kdepimlibs's upper case headers under `include/KDE`.
+    NIX_CFLAGS_COMPILE = "-I${kdepimlibs}/include/KDE";
+
+    # Help digiKam find libusb, otherwise gphoto2 support is disabled
+    cmakeFlags = [
+      "-DLIBUSB_LIBRARIES=${libusb1.out}/lib"
+      "-DLIBUSB_INCLUDE_DIR=${libusb1}/include/libusb-1.0"
+      "-DENABLE_BALOOSUPPORT=ON"
+      "-DENABLE_KDEPIMLIBSSUPPORT=ON"
+      "-DENABLE_LCMS2=ON" ] 
+    ++ stdenv.lib.optional (kfaceSupport && null == libkface) [ "-DDIGIKAMSC_COMPILE_LIBKFACE=ON" ]
+    ++ stdenv.lib.optional (kgeomapSupport && null == libkgeomap) [ "-DDIGIKAMSC_COMPILE_LIBKGEOMAP=ON" ];
 
-  src = fetchurl {
-    url = "http://download.kde.org/stable/digikam/${name}.tar.bz2";
-    sha256 = "081ldsaf3frf5khznjd3sxkjmi4dyp6w6nqnc2a0agkk0kxkl10m";
+    enableParallelBuilding = true;
+
+    meta = {
+      description = "Photo Management Program";
+      license = stdenv.lib.licenses.gpl2;
+      homepage = http://www.digikam.org;
+      maintainers = with stdenv.lib.maintainers; [ goibhniu viric urkud ];
+      inherit (kdelibs.meta) platforms;
+    };
   };
 
-  nativeBuildInputs = [ automoc4 cmake gettext perl pkgconfig ];
 
-  buildInputs = [
-    boost eigen jasper kdelibs kdepimlibs lcms lensfun libgphoto2
-    libjpeg libkdcraw libkexiv2 libkipi liblqr1 libpgf libtiff marble
-    mysql.lib opencv phonon qca2 qimageblitz qjson qt4
-    shared_desktop_ontologies soprano
+  kdePkgs = [
+    build # digikam's own build
+    kdelibs kdepimlibs kde_runtime kde_baseapps libkdcraw oxygen_icons
+    /*phonon_backend_gstreamer*/ phonon_backend_vlc
+    ffmpegthumbs /*mplayerthumbs*/ shared_mime_info ]
+  # Optional build time dependencies
+  ++ [
+
+    baloo kfilemetadata ] 
+  ++ stdenv.lib.optional (kfaceSupport && null != libkface) [ libkface ]
+  ++ stdenv.lib.optional (kgeomapSupport && null != libkgeomap) [ libkgeomap ] 
+  ++ [ 
+    libkipi ] 
+  # Plugins optional build time dependencies
+  ++ [
+    libksane libkvkontakte
   ];
 
-  # Make digikam find some FindXXXX.cmake
-  KDEDIRS="${marble}:${qjson}";
 
-  # Help digiKam find libusb, otherwise gphoto2 support is disabled
-  cmakeFlags = [
-    "-DLIBUSB_LIBRARIES=${libusb1.out}/lib"
-    "-DLIBUSB_INCLUDE_DIR=${libusb1}/include/libusb-1.0"
-    "-DDIGIKAMSC_COMPILE_LIBKFACE=ON"
-  ];
+  # TODO: It should be the responsability of these packages to add themselves to `KDEDIRS`. See
+  # <https://github.com/ttuegel/nixpkgs/commit/a0efeacc0ef2cf63bbb768bfb172a483307d080b> for
+  # a practical example.
+  # IMPORTANT: Note that using `XDG_DATA_DIRS` here instead of `KDEDIRS` won't work properly.
+  KDEDIRS = with stdenv.lib; concatStrings (intersperse ":" (map (x: "${x}") kdePkgs));
+
+  sycocaDirRelPath = "var/lib/kdesycoca";
+  sycocaFileRelPath = "${sycocaDirRelPath}/${pName}.sycoca";
+
+  sycoca = runCommand "${pName}" {
+
+    name = "digikam-sycoca-${version}";
+
+    nativeBuildInputs = [ kdelibs ];
+
+    dontPatchELF = true;
+    dontStrip = true;
+
+  } ''
+    # Make sure kbuildsycoca4 does not attempt to write to user home directory.
+    export HOME=$PWD
 
-  enableParallelBuilding = true;
+    export KDESYCOCA="$out/${sycocaFileRelPath}"
+
+    mkdir -p $out/${sycocaDirRelPath}
+    export XDG_DATA_DIRS=""
+    export KDEDIRS="${KDEDIRS}"
+    kbuildsycoca4 --noincremental --nosignal
+  '';
+
+
+  replaceExeListWithWrapped = 
+    let f = exeName: ''
+        rm -f "$out/bin/${exeName}"
+        makeWrapper "${build}/bin/${exeName}" "$out/bin/${exeName}" \
+          --set XDG_DATA_DIRS "" \
+          --set KDEDIRS "${KDEDIRS}" \
+          --set KDESYCOCA "${sycoca}/${sycocaFileRelPath}"
+      '';
+    in 
+      with stdenv.lib; exeNameList: concatStrings (intersperse "\n" (map f exeNameList));
+
+in
+
+
+with stdenv.lib;
+
+/*
+  Final derivation
+  ----------------
+
+   -  Create symlinks to our original build derivation items.
+   -  Wrap specific executables so that they know of the appropriate
+      sycoca database, `KDEDIRS` to use and block any interference
+      from `XDG_DATA_DIRS` (only `dnginfo` is not wrapped).
+*/
+runCommand "${pName}" {
+  inherit build;
+  inherit sycoca;
+
+  nativeBuildInputs = [ makeWrapper ];
+
+  buildInputs = kdePkgs;
+
+  dontPatchELF = true;
+  dontStrip = true;
 
   meta = {
     description = "Photo Management Program";
     license = stdenv.lib.licenses.gpl2;
     homepage = http://www.digikam.org;
-    maintainers = with stdenv.lib.maintainers; [ goibhniu viric urkud ];
+    maintainers = with stdenv.lib.maintainers; [ /*jraygauthier*/ ];
     inherit (kdelibs.meta) platforms;
   };
-}
+
+} ''
+  pushd $build > /dev/null
+  for d in `find . -maxdepth 1 -name "*" -printf "%f\n" | tail -n+2`; do
+    mkdir -p $out/$d
+    for f in `find $d -maxdepth 1 -name "*" -printf "%f\n" | tail -n+2`; do
+        ln -s "$build/$d/$f" "$out/$d/$f"
+    done
+  done
+  popd > /dev/null
+  
+  ${replaceExeListWithWrapped [ "cleanup_digikamdb" "digitaglinktree" "digikam" "dngconverter" 
+                                "expoblending" "photolayoutseditor" "scangui" "showfoto" ]}
+''
+
+/*
+  
+TODO
+----
+
+### Useful ###
+
+ -  Per lib `KDELIBS` environment variable export. See above in-code TODO comment.
+ -  Missing optional `qt_soap` or `herqq` (av + normal package) dependencies. Those are not
+    yet (or not fully) packaged in nix. Mainly required for upnp export.
+ -  Possibility to use the `phonon_backend_gstreamer` with its own user specified set of backend.
+ -  Allow user to disable optional features or dependencies reacting properly.
+ -  Compile `kipiplugins` as a separate package (so that it can be used by other kde packages
+    and so that this package's build time is reduced).
+
+### Not so useful ###
+
+ -  Missing optional `qt_koauth` (not packaged in nix).
+ -  Missing optional `libmediawiki` (not packaged in nix)..
+ -  For some reason the cmake build does not detect `libkvkontakte`. Fix this.
+ -  Possibility to use `mplayerthumbs` thumbnail creator backend. In digikam dev docs,
+    it is however suggested to use `ffmpegthumbs`. Maybe we should stick to it.
+
+*/
diff --git a/pkgs/applications/graphics/giv/build.patch b/pkgs/applications/graphics/giv/build.patch
index 639d881f4159..ec343c902386 100644
--- a/pkgs/applications/graphics/giv/build.patch
+++ b/pkgs/applications/graphics/giv/build.patch
@@ -15,30 +15,3 @@ index 16eccd9..603e931 100644
  
  env['SBOX'] = False
  
-diff --git a/giv/SConstruct b/giv/SConstruct
-index 047839a..2c267aa 100644
---- a/giv/SConstruct
-+++ b/giv/SConstruct
-@@ -3,8 +3,9 @@
- 
- import sys
- import re
-+import os
- 
--env = Environment()
-+env = Environment(ENV = os.environ)
- 
- src = ["giv.c",
-        "giv-backstore.c",
-diff --git a/src/plugins/dcmtk/SConstruct.standalone b/src/plugins/dcmtk/SConstruct.standalone
-index ffce001..74246f8 100644
---- a/src/plugins/dcmtk/SConstruct.standalone
-+++ b/src/plugins/dcmtk/SConstruct.standalone
-@@ -1,4 +1,6 @@
--env = Environment()
-+import os
-+
-+env = Environment(ENV = os.environ)
- 
- variant = "Debug"
- 
diff --git a/pkgs/applications/graphics/giv/default.nix b/pkgs/applications/graphics/giv/default.nix
index 2e9d55a3f3f2..f9ea3173b430 100644
--- a/pkgs/applications/graphics/giv/default.nix
+++ b/pkgs/applications/graphics/giv/default.nix
@@ -1,12 +1,14 @@
-{ stdenv, fetchurl, gdk_pixbuf, scons, pkgconfig, gtk, glib,
+{ stdenv, fetchFromGitHub, gdk_pixbuf, scons, pkgconfig, gtk, glib,
   pcre, cfitsio, perl, gob2, vala, libtiff, json_glib }:
 
 stdenv.mkDerivation rec {
-  name = "giv-0.9.22";
+  name = "giv-20150811-git";
 
-  src = fetchurl {
-    url = "mirror://sourceforge/giv/${name}.tar.gz";
-    sha256 = "1q0806b66ajppxbv1i71wx5d3ydc1h3hsz23m6g4g80dhiai7dly";
+  src = fetchFromGitHub {
+    owner = "dov";
+    repo = "giv";
+    rev = "64648bfbbf10ec4a9adfbc939c96c7d1dbdce57a";
+    sha256 = "1sz2n7jbmg3g97bs613xxjpzqbsl5rvpg6v7g3x3ycyd35r8vsfp";
   };
 
   # It built code to be put in a shared object without -fPIC
diff --git a/pkgs/applications/graphics/hugin/default.nix b/pkgs/applications/graphics/hugin/default.nix
index 97181cb0d1bf..338b3cf0f97e 100644
--- a/pkgs/applications/graphics/hugin/default.nix
+++ b/pkgs/applications/graphics/hugin/default.nix
@@ -1,6 +1,6 @@
 { stdenv, cmake, fetchurl, gnumake, pkgconfig, makeWrapper
 , boost, gettext, tclap, wxGTK
-, freeglut, glew, libXi, libXmu, mesa
+, freeglut, glew, libX11, libXi, libXmu, mesa, cairo
 , autopanosiftc, enblend-enfuse, exiv2, fftw, ilmbase, lensfun, libpng, libtiff
 , openexr, panotools, perlPackages, sqlite, vigra
 }:
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE = "-I${ilmbase}/include/OpenEXR";
 
   buildInputs = [ boost gettext tclap wxGTK
-                  freeglut glew libXi libXmu mesa
+                  freeglut glew libX11 libXi libXmu mesa cairo
                   exiv2 fftw ilmbase lensfun libtiff libpng openexr panotools
                   sqlite vigra
                   perlPackages.ImageExifTool makeWrapper
diff --git a/pkgs/applications/graphics/leocad/default.nix b/pkgs/applications/graphics/leocad/default.nix
index eaaf047c9bb3..9ca9c5921028 100644
--- a/pkgs/applications/graphics/leocad/default.nix
+++ b/pkgs/applications/graphics/leocad/default.nix
@@ -16,8 +16,11 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ qt4 zlib ];
 
-  prefixKey="INSTALL_PREFIX=";
+  prefixKey = "INSTALL_PREFIX=";
   configureScript = "qmake leocad.pro";
+  postPatch = ''
+    substituteInPlace common/camera.cpp --replace "isnan(" "std::isnan("
+  '';
 
   meta = with stdenv.lib; {
     description = "CAD program for creating virtual LEGO models";
diff --git a/pkgs/applications/graphics/openimageio/default.nix b/pkgs/applications/graphics/openimageio/default.nix
index 97607e819514..79db732750dd 100644
--- a/pkgs/applications/graphics/openimageio/default.nix
+++ b/pkgs/applications/graphics/openimageio/default.nix
@@ -4,11 +4,11 @@
 
 stdenv.mkDerivation rec {
   name = "openimageio-${version}";
-  version = "1.6.9";
+  version = "1.6.11";
 
   src = fetchurl {
     url = "https://github.com/OpenImageIO/oiio/archive/Release-${version}.zip";
-    sha256 = "0942xj877875f4dpfg7aqwyw015y82vkhaqap7yhybmvzsfj7wki";
+    sha256 = "0cr0z81a41bg193dx9crcq1mns7mmzz7qys4lrbm18cmdbwkk88x";
   };
 
   buildInputs = [
diff --git a/pkgs/applications/graphics/pencil/default.nix b/pkgs/applications/graphics/pencil/default.nix
index 8ee39c135ef8..80774fba5ff2 100644
--- a/pkgs/applications/graphics/pencil/default.nix
+++ b/pkgs/applications/graphics/pencil/default.nix
@@ -1,12 +1,12 @@
 { stdenv, fetchurl, makeWrapper, xulrunner }:
 
 stdenv.mkDerivation rec {
-  version = "2.0.15";
+  version = "2.0.18";
   name = "pencil-${version}";
 
   src = fetchurl {
     url = "https://github.com/prikhi/pencil/releases/download/v${version}/Pencil-${version}-linux-pkg.tar.gz";
-    sha256 = "be338558b613f51506337a2c7c80f209e8644656c2925f41c294e2872feabc3b";
+    sha256 = "0x0kibb2na12fwl0x68xhkjpbm5h2widm346cx2r29gp1kq9kklc";
   };
 
   buildPhase = "";
diff --git a/pkgs/applications/graphics/phototonic/default.nix b/pkgs/applications/graphics/phototonic/default.nix
index 6803b969b4b5..a26346add7ff 100644
--- a/pkgs/applications/graphics/phototonic/default.nix
+++ b/pkgs/applications/graphics/phototonic/default.nix
@@ -2,12 +2,14 @@
 
 stdenv.mkDerivation rec {
   name = "phototonic-${version}";
-  version = "1.7";
+  version = "1.7.1";
 
   src = fetchFromGitHub {
     repo = "phototonic";
     owner = "oferkv";
-    rev = "v${version}";
+    # There is currently no tag for 1.7.1 see
+    # https://github.com/oferkv/phototonic/issues/214
+    rev = "c37070e4a068570d34ece8de1e48aa0882c80c5b";
     sha256 = "1agd3bsrpljd019qrjvlbim5l0bhpx53dhpc0gvyn0wmcdzn92gj";
   };
 
diff --git a/pkgs/applications/graphics/sane/backends/git.nix b/pkgs/applications/graphics/sane/backends/git.nix
index 84e1f783e2a3..b285edd71e03 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-03-05";
+  version = "2016-03-24";
   src = fetchgit {
-    sha256 = "dc84530d5e0233427acfd132aa08a4cf9973c936ff72a66ee08ecf836200d367";
-    rev = "23eb95582da718791103b83ea002e947caa0f5fc";
+    sha256 = "593672ccfef6e3e0f3cb8ae4bbc67db9b2f1a821df4914343e4cf32f75cea865";
+    rev = "41a416e4afcf6cada69193dc408ef184d0e5f678";
     url = "git://alioth.debian.org/git/sane/sane-backends.git";
   };
 })
diff --git a/pkgs/applications/graphics/simple-scan/default.nix b/pkgs/applications/graphics/simple-scan/default.nix
index 7ee298f72811..417d117d6886 100644
--- a/pkgs/applications/graphics/simple-scan/default.nix
+++ b/pkgs/applications/graphics/simple-scan/default.nix
@@ -3,11 +3,11 @@
 
 stdenv.mkDerivation rec {
   name = "simple-scan-${version}";
-  version = "3.19.91";
+  version = "3.20.0";
 
   src = fetchurl {
-    sha256 = "1c5glf5vxgld41w4jxfqcv17q76qnh43fawpv33hncgh8d283xkf";
-    url = "https://launchpad.net/simple-scan/3.19/${version}/+download/${name}.tar.xz";
+    sha256 = "0b5ndrjwi7yipkr9bhyifpbdil65izdm677if23yj832n2jsbxcd";
+    url = "https://launchpad.net/simple-scan/3.20/${version}/+download/${name}.tar.xz";
   };
 
   buildInputs = [ cairo colord glib gusb gtk3 libusb1 libxml2 sane-backends
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
   configureFlags = [ "--disable-packagekit" ];
 
   preBuild = ''
-    # Clean up stale .c files referencing packagekit headers as of 3.19.91:
+    # Clean up stale .c files referencing packagekit headers as of 3.20.0:
     make clean
   '';
 
diff --git a/pkgs/applications/graphics/wings/default.nix b/pkgs/applications/graphics/wings/default.nix
index 9e6d6fe492a3..9ecf94e21c01 100644
--- a/pkgs/applications/graphics/wings/default.nix
+++ b/pkgs/applications/graphics/wings/default.nix
@@ -1,29 +1,34 @@
-{ fetchurl, stdenv, erlang, esdl }:
+{ fetchurl, stdenv, erlang, esdl, cl }:
 
 stdenv.mkDerivation rec {
-  name = "wings-1.4.1";
+  name = "wings-1.5.4";
   src = fetchurl {
     url = "mirror://sourceforge/wings/${name}.tar.bz2";
-    sha256 = "16kqy92rapmbvkc58mc50cidp1pm8nlwlwx69riyadc9w4qs9bji";
+    sha256 = "0qz6rmmkqgk3p0d3v2ikkf22n511bq0m7xp3kkradwrp28fcl15x";
   };
 
-  ERL_LIBS = "${esdl}/lib/erlang/addons";
+  ERL_LIBS = "${esdl}/lib/erlang/lib:${cl}/lib/erlang/lib";
 
   patchPhase = ''
     sed -i 's,include("sdl_keyboard.hrl"),include_lib("esdl/include/sdl_keyboard.hrl"),' \
       src/wings_body.erl plugins_src/commands/wpc_constraints.erl
+
+    # Fix reference
+    sed -i 's,wings/e3d/,,' plugins_src/import_export/wpc_lwo.erl
   '';
 
-  buildInputs = [ erlang esdl ];
+  buildInputs = [ erlang esdl cl ];
 
+  # I did not test the *cl* part. I added the -pa just by imitation.
   installPhase = ''
     mkdir -p $out/bin $out/lib/${name}/ebin
     cp ebin/* $out/lib/${name}/ebin
     cp -R fonts textures shaders plugins $out/lib/$name
     cat << EOF > $out/bin/wings
     #!/bin/sh
-    export ROOTDIR=$out/lib/erlang/addons/${name}
-    ${erlang}/bin/erl -smp disable -pa ${esdl}/lib/erlang/addons/${esdl.name}/ebin \
+    ${erlang}/bin/erl -smp disable \
+      -pa ${esdl}/lib/erlang/lib/${cl.name}/ebin \
+      -pa ${esdl}/lib/erlang/lib/${esdl.name}/ebin \
       -pa $out/lib/${name}/ebin -run wings_start start_halt "$@"
     EOF
     chmod +x $out/bin/wings