about summary refs log tree commit diff
path: root/pkgs/applications/graphics
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r--pkgs/applications/graphics/ahoviewer/default.nix1
-rw-r--r--pkgs/applications/graphics/antimony/default.nix1
-rw-r--r--pkgs/applications/graphics/apngasm/2.nix1
-rw-r--r--pkgs/applications/graphics/blockbench-electron/default.nix48
-rw-r--r--pkgs/applications/graphics/cloudcompare/default.nix46
-rw-r--r--pkgs/applications/graphics/conjure/default.nix1
-rw-r--r--pkgs/applications/graphics/curtail/default.nix1
-rw-r--r--pkgs/applications/graphics/dia/default.nix1
-rw-r--r--pkgs/applications/graphics/displaycal/default.nix75
-rw-r--r--pkgs/applications/graphics/djview/default.nix1
-rw-r--r--pkgs/applications/graphics/dosage/default.nix1
-rw-r--r--pkgs/applications/graphics/drawing/default.nix1
-rw-r--r--pkgs/applications/graphics/drawio/default.nix14
-rw-r--r--pkgs/applications/graphics/drawpile/default.nix1
-rw-r--r--pkgs/applications/graphics/eddy/default.nix1
-rw-r--r--pkgs/applications/graphics/emblem/default.nix1
-rw-r--r--pkgs/applications/graphics/evilpixie/default.nix1
-rw-r--r--pkgs/applications/graphics/eyedropper/default.nix1
-rw-r--r--pkgs/applications/graphics/fiji/default.nix1
-rw-r--r--pkgs/applications/graphics/fstl/default.nix1
-rw-r--r--pkgs/applications/graphics/gcolor3/default.nix1
-rw-r--r--pkgs/applications/graphics/geeqie/default.nix1
-rw-r--r--pkgs/applications/graphics/gnome-photos/default.nix1
-rw-r--r--pkgs/applications/graphics/goxel/default.nix1
-rw-r--r--pkgs/applications/graphics/gthumb/default.nix1
-rw-r--r--pkgs/applications/graphics/hdrmerge/default.nix1
-rw-r--r--pkgs/applications/graphics/icon-library/default.nix1
-rw-r--r--pkgs/applications/graphics/identity/default.nix1
-rw-r--r--pkgs/applications/graphics/image-roll/default.nix1
-rw-r--r--pkgs/applications/graphics/imgp/default.nix1
-rw-r--r--pkgs/applications/graphics/kgraphviewer/default.nix1
-rw-r--r--pkgs/applications/graphics/komikku/default.nix1
-rw-r--r--pkgs/applications/graphics/krop/default.nix1
-rw-r--r--pkgs/applications/graphics/ktikz/default.nix1
-rw-r--r--pkgs/applications/graphics/leocad/default.nix1
-rw-r--r--pkgs/applications/graphics/lightburn/default.nix4
-rw-r--r--pkgs/applications/graphics/mandelbulber/default.nix1
-rw-r--r--pkgs/applications/graphics/meshlab/default.nix1
-rw-r--r--pkgs/applications/graphics/oculante/default.nix6
-rw-r--r--pkgs/applications/graphics/opentoonz/default.nix105
-rw-r--r--pkgs/applications/graphics/opentoonz/libtiff.nix56
-rw-r--r--pkgs/applications/graphics/opentoonz/source.nix16
-rw-r--r--pkgs/applications/graphics/ovito/default.nix1
-rw-r--r--pkgs/applications/graphics/paleta/default.nix1
-rw-r--r--pkgs/applications/graphics/pencil/default.nix1
-rw-r--r--pkgs/applications/graphics/photoflare/default.nix1
-rw-r--r--pkgs/applications/graphics/photoqt/default.nix18
-rw-r--r--pkgs/applications/graphics/phototonic/default.nix1
-rw-r--r--pkgs/applications/graphics/pick-colour-picker/default.nix1
-rw-r--r--pkgs/applications/graphics/pikopixel/default.nix3
-rw-r--r--pkgs/applications/graphics/pizarra/default.nix1
-rw-r--r--pkgs/applications/graphics/qcomicbook/default.nix1
-rw-r--r--pkgs/applications/graphics/qimgv/default.nix1
-rw-r--r--pkgs/applications/graphics/qosmic/default.nix1
-rw-r--r--pkgs/applications/graphics/qscreenshot/default.nix1
-rw-r--r--pkgs/applications/graphics/qvge/default.nix1
-rw-r--r--pkgs/applications/graphics/qview/default.nix1
-rw-r--r--pkgs/applications/graphics/rapid-photo-downloader/default.nix1
-rw-r--r--pkgs/applications/graphics/rx/default.nix1
-rw-r--r--pkgs/applications/graphics/sane/backends/airscan/default.nix9
-rw-r--r--pkgs/applications/graphics/sane/xsane.nix1
-rw-r--r--pkgs/applications/graphics/scantailor/advanced.nix1
-rw-r--r--pkgs/applications/graphics/shotwell/default.nix1
-rw-r--r--pkgs/applications/graphics/shutter/default.nix1
-rw-r--r--pkgs/applications/graphics/smartdeblur/default.nix1
-rw-r--r--pkgs/applications/graphics/structorizer/default.nix4
-rw-r--r--pkgs/applications/graphics/symbolic-preview/default.nix1
-rw-r--r--pkgs/applications/graphics/tev/default.nix1
-rw-r--r--pkgs/applications/graphics/timelapse-deflicker/default.nix1
-rw-r--r--pkgs/applications/graphics/vengi-tools/default.nix4
-rw-r--r--pkgs/applications/graphics/vengi-tools/test-voxconvert-all-formats.nix2
-rw-r--r--pkgs/applications/graphics/vengi-tools/test-voxconvert-roundtrip.nix2
-rw-r--r--pkgs/applications/graphics/veusz/default.nix1
-rw-r--r--pkgs/applications/graphics/weylus/default.nix1
-rw-r--r--pkgs/applications/graphics/xaos/default.nix1
-rw-r--r--pkgs/applications/graphics/xfig/default.nix1
-rw-r--r--pkgs/applications/graphics/xpano/default.nix1
-rw-r--r--pkgs/applications/graphics/xrgears/default.nix1
78 files changed, 232 insertions, 242 deletions
diff --git a/pkgs/applications/graphics/ahoviewer/default.nix b/pkgs/applications/graphics/ahoviewer/default.nix
index d903ce1adf8e..4c1d309ebbab 100644
--- a/pkgs/applications/graphics/ahoviewer/default.nix
+++ b/pkgs/applications/graphics/ahoviewer/default.nix
@@ -42,6 +42,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://github.com/ahodesuka/ahoviewer";
     description = "A GTK2 image viewer, manga reader, and booru browser";
+    mainProgram = "ahoviewer";
     maintainers = with maintainers; [ xzfc ];
     license = licenses.mit;
     # Unintentionally not working on Darwin:
diff --git a/pkgs/applications/graphics/antimony/default.nix b/pkgs/applications/graphics/antimony/default.nix
index 50156802779c..56ee01f8bbe8 100644
--- a/pkgs/applications/graphics/antimony/default.nix
+++ b/pkgs/applications/graphics/antimony/default.nix
@@ -62,6 +62,7 @@ in
 
     meta = with lib; {
       description = "A computer-aided design (CAD) tool from a parallel universe";
+      mainProgram = "antimony";
       homepage    = "https://github.com/mkeeter/antimony";
       license     = licenses.mit;
       maintainers = with maintainers; [ rnhmjoj ];
diff --git a/pkgs/applications/graphics/apngasm/2.nix b/pkgs/applications/graphics/apngasm/2.nix
index 81d2915c96df..f581f9dd1245 100644
--- a/pkgs/applications/graphics/apngasm/2.nix
+++ b/pkgs/applications/graphics/apngasm/2.nix
@@ -26,6 +26,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Create highly optimized Animated PNG files from PNG/TGA images";
+    mainProgram = "apngasm";
     homepage = "https://apngasm.sourceforge.net/";
     license = licenses.zlib;
     maintainers = with maintainers; [ orivej ];
diff --git a/pkgs/applications/graphics/blockbench-electron/default.nix b/pkgs/applications/graphics/blockbench-electron/default.nix
deleted file mode 100644
index 50a10310546d..000000000000
--- a/pkgs/applications/graphics/blockbench-electron/default.nix
+++ /dev/null
@@ -1,48 +0,0 @@
-{ lib, stdenv, fetchurl, appimageTools, makeWrapper, electron_25 }:
-
-stdenv.mkDerivation rec {
-  pname = "blockbench-electron";
-  version = "4.8.1";
-
-  src = fetchurl {
-    url = "https://github.com/JannisX11/blockbench/releases/download/v${version}/Blockbench_${version}.AppImage";
-    sha256 = "sha256-CE2wDOt1WBcYmPs4sEyZ3LYvKLequFZH0B3huMYHlwA=";
-    name = "${pname}-${version}.AppImage";
-  };
-
-  appimageContents = appimageTools.extractType2 {
-    name = "${pname}-${version}";
-    inherit src;
-  };
-
-  dontUnpack = true;
-  dontConfigure = true;
-  dontBuild = true;
-
-  nativeBuildInputs = [ makeWrapper ];
-
-  installPhase = ''
-    runHook preInstall
-    mkdir -p $out/bin $out/share/${pname} $out/share/applications
-    cp -a ${appimageContents}/{locales,resources} $out/share/${pname}
-    cp -a ${appimageContents}/blockbench.desktop $out/share/applications/${pname}.desktop
-    cp -a ${appimageContents}/usr/share/icons $out/share
-    substituteInPlace $out/share/applications/${pname}.desktop \
-      --replace 'Exec=AppRun' 'Exec=${pname}'
-    runHook postInstall
-  '';
-
-  postFixup = ''
-    makeWrapper ${electron_25}/bin/electron $out/bin/${pname} \
-      --add-flags $out/share/${pname}/resources/app.asar \
-      --prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ stdenv.cc.cc ]}"
-  '';
-
-  meta = with lib; {
-    description = "A boxy 3D model editor powered by Electron";
-    homepage = "https://blockbench.net/";
-    license = licenses.gpl3Only;
-    maintainers = with maintainers; [ ckie ];
-    platforms = [ "x86_64-linux" ];
-  };
-}
diff --git a/pkgs/applications/graphics/cloudcompare/default.nix b/pkgs/applications/graphics/cloudcompare/default.nix
index 1ad3476e8091..e78b95c363b6 100644
--- a/pkgs/applications/graphics/cloudcompare/default.nix
+++ b/pkgs/applications/graphics/cloudcompare/default.nix
@@ -2,6 +2,8 @@
 , stdenv
 , mkDerivation
 , fetchFromGitHub
+, makeDesktopItem
+, copyDesktopItems
 , cmake
 , boost
 , cgal
@@ -23,13 +25,13 @@
 
 mkDerivation rec {
   pname = "cloudcompare";
-  version = "2.13";
+  version = "2.13.1";
 
   src = fetchFromGitHub {
     owner = "CloudCompare";
     repo = "CloudCompare";
     rev = "v${version}";
-    hash = "sha256-tCmIdajizaTT1tvPA7YQoklfz7pYVKS0lJXrxV2fidg=";
+    hash = "sha256-QQwQt63tXxJnGaBLu+GvWkEazumYPhXnDe+giSu7wjk=";
     fetchSubmodules = true;
   };
 
@@ -37,6 +39,7 @@ mkDerivation rec {
     cmake
     eigen # header-only
     wrapGAppsHook
+    copyDesktopItems
   ];
 
   buildInputs = [
@@ -96,12 +99,15 @@ mkDerivation rec {
   dontWrapGApps = true;
 
   postInstall = ''
-    install -Dm444 $src/snap/gui/{ccViewer,cloudcompare}.png -t $out/share/icons/hicolor/256x256/apps
-    install -Dm444 $src/snap/gui/{ccViewer,cloudcompare}.desktop -t $out/share/applications
-    substituteInPlace $out/share/applications/{ccViewer,cloudcompare}.desktop \
-      --replace 'Exec=cloudcompare.' 'Exec=' \
-      --replace 'Icon=''${SNAP}/meta/gui/' 'Icon=' \
-      --replace '.png' ""
+    install -Dm444 $src/qCC/images/icon/cc_icon_16.png $out/share/icons/hicolor/16x16/apps/CloudCompare.png
+    install -Dm444 $src/qCC/images/icon/cc_icon_32.png $out/share/icons/hicolor/32x32/apps/CloudCompare.png
+    install -Dm444 $src/qCC/images/icon/cc_icon_64.png $out/share/icons/hicolor/64x64/apps/CloudCompare.png
+    install -Dm444 $src/qCC/images/icon/cc_icon_256.png $out/share/icons/hicolor/256x256/apps/CloudCompare.png
+
+    install -Dm444 $src/qCC/images/icon/cc_viewer_icon_16.png $out/share/icons/hicolor/16x16/apps/ccViewer.png
+    install -Dm444 $src/qCC/images/icon/cc_viewer_icon_32.png $out/share/icons/hicolor/32x32/apps/ccViewer.png
+    install -Dm444 $src/qCC/images/icon/cc_viewer_icon_64.png $out/share/icons/hicolor/64x64/apps/ccViewer.png
+    install -Dm444 $src/qCC/images/icon/cc_viewer_icon_256.png $out/share/icons/hicolor/256x256/apps/ccViewer.png
   '';
 
   # fix file dialogs crashing on non-NixOS (and avoid double wrapping)
@@ -109,11 +115,35 @@ mkDerivation rec {
     qtWrapperArgs+=("''${gappsWrapperArgs[@]}")
   '';
 
+  desktopItems = [
+    (makeDesktopItem {
+      name = "CloudCompare";
+      desktopName = "CloudCompare";
+      comment = "3D point cloud and mesh processing software";
+      exec = "CloudCompare";
+      terminal = false;
+      categories = [ "Graphics" "3DGraphics" "Viewer" ];
+      keywords = [ "3d" "processing" ];
+      icon = "CloudCompare";
+    })
+    (makeDesktopItem {
+      name = "ccViewer";
+      desktopName = "CloudCompare Viewer";
+      comment = "3D point cloud and mesh processing software";
+      exec = "ccViewer";
+      terminal = false;
+      categories = [ "Graphics" "3DGraphics" "Viewer" ];
+      keywords = [ "3d" "viewer" ];
+      icon = "ccViewer";
+    })
+  ];
+
   meta = with lib; {
     description = "3D point cloud and mesh processing software";
     homepage = "https://cloudcompare.org";
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ nh2 ];
+    mainProgram = "CloudCompare";
     platforms = with platforms; linux; # only tested here; might work on others
   };
 }
diff --git a/pkgs/applications/graphics/conjure/default.nix b/pkgs/applications/graphics/conjure/default.nix
index b0b00369ffde..634cf7132b1d 100644
--- a/pkgs/applications/graphics/conjure/default.nix
+++ b/pkgs/applications/graphics/conjure/default.nix
@@ -57,6 +57,7 @@ python3Packages.buildPythonApplication rec {
 
   meta = with lib; {
     description = "Magically transform your images";
+    mainProgram = "conjure";
     longDescription = ''
       Resize, crop, rotate, flip images, apply various filters and effects,
       adjust levels and brightness, and much more. An intuitive tool for designers,
diff --git a/pkgs/applications/graphics/curtail/default.nix b/pkgs/applications/graphics/curtail/default.nix
index 30ca2289526b..2a881c153f68 100644
--- a/pkgs/applications/graphics/curtail/default.nix
+++ b/pkgs/applications/graphics/curtail/default.nix
@@ -69,6 +69,7 @@ python3.pkgs.buildPythonApplication rec {
 
   meta = with lib; {
     description = "Simple & useful image compressor";
+    mainProgram = "curtail";
     homepage = "https://github.com/Huluti/Curtail";
     license = licenses.gpl3Only;
     maintainers = with maintainers; [ anselmschueler ];
diff --git a/pkgs/applications/graphics/dia/default.nix b/pkgs/applications/graphics/dia/default.nix
index eb9d54d5cfc1..c79f50e86d79 100644
--- a/pkgs/applications/graphics/dia/default.nix
+++ b/pkgs/applications/graphics/dia/default.nix
@@ -68,6 +68,7 @@ stdenv.mkDerivation {
 
   meta = with lib; {
     description = "Gnome Diagram drawing software";
+    mainProgram = "dia";
     homepage = "http://live.gnome.org/Dia";
     maintainers = with maintainers; [ raskin ];
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/displaycal/default.nix b/pkgs/applications/graphics/displaycal/default.nix
deleted file mode 100644
index 0eef148398cb..000000000000
--- a/pkgs/applications/graphics/displaycal/default.nix
+++ /dev/null
@@ -1,75 +0,0 @@
-{ lib
-, python3
-, fetchPypi
-, wrapGAppsHook
-, gtk3
-, librsvg
-, xorg
-, argyllcms
-}:
-
-python3.pkgs.buildPythonApplication rec {
-  pname = "displaycal";
-  version = "3.9.11";
-  format = "setuptools";
-
-  src = fetchPypi {
-    pname = "DisplayCAL";
-    inherit version;
-    hash = "sha256-zAZW2eMjwRYevlz8KEzTxzGO8vx5AydfY3vGTapNo1c=";
-  };
-
-  nativeBuildInputs = [
-    wrapGAppsHook
-    gtk3
-  ];
-
-  propagatedBuildInputs = with python3.pkgs; [
-    build
-    certifi
-    wxpython
-    dbus-python
-    distro
-    numpy
-    pillow
-    pychromecast
-    send2trash
-    zeroconf
-  ];
-
-  buildInputs = [
-    gtk3
-    librsvg
-  ] ++ (with xorg; [
-    libX11
-    libXxf86vm
-    libXext
-    libXinerama
-    libXrandr
-  ]);
-
-  # Workaround for eoyilmaz/displaycal-py3#261
-  setupPyGlobalFlags = [ "appdata" ];
-
-  doCheck = false; # Tests try to access an X11 session and dbus in weird locations.
-
-  pythonImportsCheck = [ "DisplayCAL" ];
-
-  dontWrapGApps = true;
-
-  preFixup = ''
-    makeWrapperArgs+=(
-      ''${gappsWrapperArgs[@]}
-      --prefix PATH : ${lib.makeBinPath [ argyllcms ]}
-      --prefix PYTHONPATH : $PYTHONPATH
-    )
-  '';
-
-  meta = with lib; {
-    description = "Display calibration and characterization powered by Argyll CMS (Migrated to Python 3)";
-    homepage = "https://github.com/eoyilmaz/displaycal-py3";
-    license = licenses.gpl3Plus;
-    platforms = platforms.linux;
-    maintainers = with maintainers; [ toastal ];
-  };
-}
diff --git a/pkgs/applications/graphics/djview/default.nix b/pkgs/applications/graphics/djview/default.nix
index 6386c39ce910..5bbbfc0c686c 100644
--- a/pkgs/applications/graphics/djview/default.nix
+++ b/pkgs/applications/graphics/djview/default.nix
@@ -46,6 +46,7 @@ mkDerivation rec {
   meta = with lib; {
     broken = stdenv.isDarwin;
     description = "A portable DjVu viewer (Qt5) and browser (nsdejavu) plugin";
+    mainProgram = "djview";
     homepage = "https://djvu.sourceforge.net/djview4.html";
     license = licenses.gpl2;
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/dosage/default.nix b/pkgs/applications/graphics/dosage/default.nix
index 6bdf149c9b97..1aaa53948619 100644
--- a/pkgs/applications/graphics/dosage/default.nix
+++ b/pkgs/applications/graphics/dosage/default.nix
@@ -23,6 +23,7 @@ python3Packages.buildPythonApplication rec {
 
   meta = {
     description = "A comic strip downloader and archiver";
+    mainProgram = "dosage";
     homepage = "https://dosage.rocks/";
     license = lib.licenses.mit;
     maintainers = with lib.maintainers; [ toonn ];
diff --git a/pkgs/applications/graphics/drawing/default.nix b/pkgs/applications/graphics/drawing/default.nix
index 693c0b213b54..90caf78d6313 100644
--- a/pkgs/applications/graphics/drawing/default.nix
+++ b/pkgs/applications/graphics/drawing/default.nix
@@ -63,6 +63,7 @@ python3.pkgs.buildPythonApplication rec {
 
   meta = with lib; {
     description = "A free basic image editor, similar to Microsoft Paint, but aiming at the GNOME desktop";
+    mainProgram = "drawing";
     homepage = "https://maoschanz.github.io/drawing/";
     changelog = "https://github.com/maoschanz/drawing/releases/tag/${version}";
     maintainers = with maintainers; [ mothsart ];
diff --git a/pkgs/applications/graphics/drawio/default.nix b/pkgs/applications/graphics/drawio/default.nix
index 08a0ba5b8125..b9c56a01e006 100644
--- a/pkgs/applications/graphics/drawio/default.nix
+++ b/pkgs/applications/graphics/drawio/default.nix
@@ -6,6 +6,7 @@
 , copyDesktopItems
 , prefetch-yarn-deps
 , makeWrapper
+, autoSignDarwinBinariesHook
 , nodejs
 , yarn
 , electron
@@ -13,19 +14,24 @@
 
 stdenv.mkDerivation rec {
   pname = "drawio";
-  version = "23.1.5";
+  version = "24.0.4";
 
   src = fetchFromGitHub {
     owner = "jgraph";
     repo = "drawio-desktop";
     rev = "v${version}";
     fetchSubmodules = true;
-    hash = "sha256-ThmTahuU0o/vr6h/T/zCyEB5/APJlVA6t1TNfZgqTJ0=";
+    hash = "sha256-+TCnVXcmAEpa7MiL0dyeoh2aUfIIO8eze9pEaHgKnME=";
   };
 
+  # `@electron/fuses` tries to run `codesign` and fails. Disable and use autoSignDarwinBinariesHook instead
+  postPatch = ''
+    sed -i -e 's/resetAdHocDarwinSignature:.*/resetAdHocDarwinSignature: false,/' build/fuses.js
+  '';
+
   offlineCache = fetchYarnDeps {
     yarnLock = src + "/yarn.lock";
-    hash = "sha256-hL89WVYy/EQe6Zppmr17Q9T2o/UjBvydDIgGpr7AA5M=";
+    hash = "sha256-QS0bkDDQq3sn79TQ+pTZsmbmXgMccyLmlPLTsko7eGg=";
   };
 
   nativeBuildInputs = [
@@ -35,6 +41,8 @@ stdenv.mkDerivation rec {
     yarn
   ] ++ lib.optionals (!stdenv.isDarwin) [
     copyDesktopItems
+  ] ++ lib.optionals stdenv.isDarwin [
+    autoSignDarwinBinariesHook
   ];
 
   ELECTRON_SKIP_BINARY_DOWNLOAD = true;
diff --git a/pkgs/applications/graphics/drawpile/default.nix b/pkgs/applications/graphics/drawpile/default.nix
index ea07e2314217..5c43c609f31f 100644
--- a/pkgs/applications/graphics/drawpile/default.nix
+++ b/pkgs/applications/graphics/drawpile/default.nix
@@ -98,6 +98,7 @@ in mkDerivation rec {
 
   meta = {
     description = "A collaborative drawing program that allows multiple users to sketch on the same canvas simultaneously";
+    mainProgram = "drawpile-srv";
     homepage = "https://drawpile.net/";
     downloadPage = "https://drawpile.net/download/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/eddy/default.nix b/pkgs/applications/graphics/eddy/default.nix
index 58b8777bb223..6dac49fc5d15 100644
--- a/pkgs/applications/graphics/eddy/default.nix
+++ b/pkgs/applications/graphics/eddy/default.nix
@@ -40,6 +40,7 @@ python3Packages.buildPythonApplication rec {
   meta = with lib; {
     homepage = "http://www.obdasystems.com/eddy";
     description = "Graphical editor for the specification and visualization of Graphol ontologies";
+    mainProgram = "eddy";
     license = licenses.gpl3Only;
     platforms = platforms.linux;
     maintainers = with maintainers; [ koslambrou ];
diff --git a/pkgs/applications/graphics/emblem/default.nix b/pkgs/applications/graphics/emblem/default.nix
index b2df35c20c4b..6d490fc24141 100644
--- a/pkgs/applications/graphics/emblem/default.nix
+++ b/pkgs/applications/graphics/emblem/default.nix
@@ -57,6 +57,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Generate project icons and avatars from a symbolic icon";
+    mainProgram = "emblem";
     homepage = "https://gitlab.gnome.org/World/design/emblem";
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/evilpixie/default.nix b/pkgs/applications/graphics/evilpixie/default.nix
index 8e6d8328a3cb..fb397239849b 100644
--- a/pkgs/applications/graphics/evilpixie/default.nix
+++ b/pkgs/applications/graphics/evilpixie/default.nix
@@ -40,6 +40,7 @@ stdenv.mkDerivation (finalAttrs: {
 
   meta = with lib; {
     description = "Pixel-oriented paint program, modelled on Deluxe Paint";
+    mainProgram = "evilpixie";
     homepage = "https://github.com/bcampbell/evilpixie"; # http://evilpixie.scumways.com/ is gone
     downloadPage = "https://github.com/bcampbell/evilpixie/releases";
     license = licenses.gpl3Only;
diff --git a/pkgs/applications/graphics/eyedropper/default.nix b/pkgs/applications/graphics/eyedropper/default.nix
index f531f8c16271..efa60ac32826 100644
--- a/pkgs/applications/graphics/eyedropper/default.nix
+++ b/pkgs/applications/graphics/eyedropper/default.nix
@@ -54,6 +54,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Pick and format colors";
+    mainProgram = "eyedropper";
     homepage = "https://github.com/FineFindus/eyedropper";
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/fiji/default.nix b/pkgs/applications/graphics/fiji/default.nix
index e3847b98d519..c5f4d08f30e4 100644
--- a/pkgs/applications/graphics/fiji/default.nix
+++ b/pkgs/applications/graphics/fiji/default.nix
@@ -65,6 +65,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://imagej.net/software/fiji/";
     description = "batteries-included distribution of ImageJ2, bundling a lot of plugins which facilitate scientific image analysis";
+    mainProgram = "fiji";
     platforms = [ "x86_64-linux" ];
     sourceProvenance = with sourceTypes; [
       binaryBytecode
diff --git a/pkgs/applications/graphics/fstl/default.nix b/pkgs/applications/graphics/fstl/default.nix
index c7faf43e24e8..a004c2dd8d77 100644
--- a/pkgs/applications/graphics/fstl/default.nix
+++ b/pkgs/applications/graphics/fstl/default.nix
@@ -24,6 +24,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "The fastest STL file viewer";
+    mainProgram = "fstl";
     homepage = "https://github.com/fstl-app/fstl";
     license = licenses.mit;
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/applications/graphics/gcolor3/default.nix b/pkgs/applications/graphics/gcolor3/default.nix
index 6895a334f1e5..ae36266f29c8 100644
--- a/pkgs/applications/graphics/gcolor3/default.nix
+++ b/pkgs/applications/graphics/gcolor3/default.nix
@@ -47,6 +47,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A simple color chooser written in GTK3";
+    mainProgram = "gcolor3";
     homepage = "https://gitlab.gnome.org/World/gcolor3";
     license = licenses.gpl2Plus;
     maintainers = with maintainers; [ ];
diff --git a/pkgs/applications/graphics/geeqie/default.nix b/pkgs/applications/graphics/geeqie/default.nix
index 653dad23b638..a064e27a6657 100644
--- a/pkgs/applications/graphics/geeqie/default.nix
+++ b/pkgs/applications/graphics/geeqie/default.nix
@@ -66,6 +66,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Lightweight GTK based image viewer";
+    mainProgram = "geeqie";
 
     longDescription =
       ''
diff --git a/pkgs/applications/graphics/gnome-photos/default.nix b/pkgs/applications/graphics/gnome-photos/default.nix
index 7a51f037f995..fbcc5ebcf478 100644
--- a/pkgs/applications/graphics/gnome-photos/default.nix
+++ b/pkgs/applications/graphics/gnome-photos/default.nix
@@ -114,6 +114,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Access, organize and share your photos";
+    mainProgram = "gnome-photos";
     homepage = "https://wiki.gnome.org/Apps/Photos";
     license = licenses.gpl3Plus;
     maintainers = teams.gnome.members;
diff --git a/pkgs/applications/graphics/goxel/default.nix b/pkgs/applications/graphics/goxel/default.nix
index 5f04312965a0..000fd3719263 100644
--- a/pkgs/applications/graphics/goxel/default.nix
+++ b/pkgs/applications/graphics/goxel/default.nix
@@ -33,6 +33,7 @@ stdenv.mkDerivation (finalAttrs: {
 
   meta = with lib; {
     description = "Open Source 3D voxel editor";
+    mainProgram = "goxel";
     homepage = "https://guillaumechereau.github.io/goxel/";
     license = licenses.gpl3;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/gthumb/default.nix b/pkgs/applications/graphics/gthumb/default.nix
index 86de9fb2aede..79793c688711 100644
--- a/pkgs/applications/graphics/gthumb/default.nix
+++ b/pkgs/applications/graphics/gthumb/default.nix
@@ -109,6 +109,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Gthumb";
     description = "Image browser and viewer for GNOME";
+    mainProgram = "gthumb";
     platforms = platforms.linux;
     license = licenses.gpl2Plus;
     maintainers = [ maintainers.mimame ];
diff --git a/pkgs/applications/graphics/hdrmerge/default.nix b/pkgs/applications/graphics/hdrmerge/default.nix
index 827ee15af60a..cfd5fe516be5 100644
--- a/pkgs/applications/graphics/hdrmerge/default.nix
+++ b/pkgs/applications/graphics/hdrmerge/default.nix
@@ -72,6 +72,7 @@ mkDerivation rec {
   meta = with lib; {
     homepage = "https://github.com/jcelaya/hdrmerge";
     description = "Combines two or more raw images into an HDR";
+    mainProgram = "hdrmerge";
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
     maintainers = [ maintainers.paperdigits ];
diff --git a/pkgs/applications/graphics/icon-library/default.nix b/pkgs/applications/graphics/icon-library/default.nix
index 6033843e4aeb..25cc1ebebfbc 100644
--- a/pkgs/applications/graphics/icon-library/default.nix
+++ b/pkgs/applications/graphics/icon-library/default.nix
@@ -48,6 +48,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://gitlab.gnome.org/World/design/icon-library";
     description = "Symbolic icons for your apps";
+    mainProgram = "icon-library";
     maintainers = with maintainers; [ qyliss ];
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/identity/default.nix b/pkgs/applications/graphics/identity/default.nix
index a17ecf7a6fb2..8d9caa58543c 100644
--- a/pkgs/applications/graphics/identity/default.nix
+++ b/pkgs/applications/graphics/identity/default.nix
@@ -69,6 +69,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A program for comparing multiple versions of an image or video";
+    mainProgram = "identity";
     homepage = "https://gitlab.gnome.org/YaLTeR/identity";
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/image-roll/default.nix b/pkgs/applications/graphics/image-roll/default.nix
index 461a07837d83..2c142b7bbb80 100644
--- a/pkgs/applications/graphics/image-roll/default.nix
+++ b/pkgs/applications/graphics/image-roll/default.nix
@@ -40,6 +40,7 @@ rustPlatform.buildRustPackage rec {
 
   meta = with lib; {
     description = "Simple and fast GTK image viewer with basic image manipulation tools";
+    mainProgram = "image-roll";
     homepage = "https://github.com/weclaw1/image-roll";
     license = licenses.mit;
     maintainers = with maintainers; [ figsoda ];
diff --git a/pkgs/applications/graphics/imgp/default.nix b/pkgs/applications/graphics/imgp/default.nix
index 995aaf2599df..bb2334222fb7 100644
--- a/pkgs/applications/graphics/imgp/default.nix
+++ b/pkgs/applications/graphics/imgp/default.nix
@@ -31,6 +31,7 @@ buildPythonApplication rec {
 
   meta = with lib; {
     description = "High-performance CLI batch image resizer & rotator";
+    mainProgram = "imgp";
     homepage = "https://github.com/jarun/imgp";
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/kgraphviewer/default.nix b/pkgs/applications/graphics/kgraphviewer/default.nix
index 4b9b93505ad8..65ec4eb71d42 100644
--- a/pkgs/applications/graphics/kgraphviewer/default.nix
+++ b/pkgs/applications/graphics/kgraphviewer/default.nix
@@ -29,6 +29,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "A Graphviz dot graph viewer for KDE";
+    mainProgram = "kgraphviewer";
     license     = licenses.gpl2;
     maintainers = with maintainers; [ ];
     platforms   = platforms.linux;
diff --git a/pkgs/applications/graphics/komikku/default.nix b/pkgs/applications/graphics/komikku/default.nix
index 4a4b499ca4d0..d69475213439 100644
--- a/pkgs/applications/graphics/komikku/default.nix
+++ b/pkgs/applications/graphics/komikku/default.nix
@@ -88,6 +88,7 @@ python3.pkgs.buildPythonApplication rec {
 
   meta = with lib; {
     description = "Manga reader for GNOME";
+    mainProgram = "komikku";
     homepage = "https://apps.gnome.org/Komikku/";
     license = licenses.gpl3Plus;
     changelog = "https://codeberg.org/valos/Komikku/releases/tag/v${version}";
diff --git a/pkgs/applications/graphics/krop/default.nix b/pkgs/applications/graphics/krop/default.nix
index 0adcf0b538d2..93e24b24b53b 100644
--- a/pkgs/applications/graphics/krop/default.nix
+++ b/pkgs/applications/graphics/krop/default.nix
@@ -37,6 +37,7 @@ python3Packages.buildPythonApplication rec {
   meta = {
     homepage = "http://arminstraub.com/software/krop";
     description = "Graphical tool to crop the pages of PDF files";
+    mainProgram = "krop";
     longDescription = ''
     Krop is a tool that allows you to optimise your PDF files, and remove
     sections of the page you do not want.  A unique feature of krop, at least to my
diff --git a/pkgs/applications/graphics/ktikz/default.nix b/pkgs/applications/graphics/ktikz/default.nix
index d176ce38f0ad..b7fe2e205fa8 100644
--- a/pkgs/applications/graphics/ktikz/default.nix
+++ b/pkgs/applications/graphics/ktikz/default.nix
@@ -14,6 +14,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Editor for the TikZ language";
+    mainProgram = "qtikz";
     homepage = "https://github.com/fhackenberger/ktikz";
     license = licenses.gpl2;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/leocad/default.nix b/pkgs/applications/graphics/leocad/default.nix
index bb37dc5ef027..9a0bbaefe505 100644
--- a/pkgs/applications/graphics/leocad/default.nix
+++ b/pkgs/applications/graphics/leocad/default.nix
@@ -56,6 +56,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "CAD program for creating virtual LEGO models";
+    mainProgram = "leocad";
     homepage = "https://www.leocad.org/";
     license = licenses.gpl2Only;
     maintainers = with maintainers; [ peterhoeg ];
diff --git a/pkgs/applications/graphics/lightburn/default.nix b/pkgs/applications/graphics/lightburn/default.nix
index 7ac16d934fa8..cd2a1f4b5184 100644
--- a/pkgs/applications/graphics/lightburn/default.nix
+++ b/pkgs/applications/graphics/lightburn/default.nix
@@ -6,7 +6,7 @@
 
 stdenv.mkDerivation rec {
   pname = "lightburn";
-  version = "1.5.02";
+  version = "1.5.04";
 
   nativeBuildInputs = [
     p7zip
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   src = fetchurl {
     url = "https://github.com/LightBurnSoftware/deployment/releases/download/${version}/LightBurn-Linux64-v${version}.7z";
-    sha256 = "sha256-1gmiPWrNk3T8WJ9u/4UzrhwxOcPUKyWIqtwqJiXA4c4=";
+    sha256 = "sha256-cyQUv/KqdtDwCFo8CatJYdepgdWNwTSMyDLzOjvvO5c=";
   };
 
   buildInputs = [
diff --git a/pkgs/applications/graphics/mandelbulber/default.nix b/pkgs/applications/graphics/mandelbulber/default.nix
index 68e88bdea28a..1f1116096821 100644
--- a/pkgs/applications/graphics/mandelbulber/default.nix
+++ b/pkgs/applications/graphics/mandelbulber/default.nix
@@ -55,6 +55,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "A 3D fractal rendering engine";
+    mainProgram = "mandelbulber2";
     longDescription = "Mandelbulber creatively generates three-dimensional fractals. Explore trigonometric, hyper-complex, Mandelbox, IFS, and many other 3D fractals.";
     homepage = "https://mandelbulber.com";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/meshlab/default.nix b/pkgs/applications/graphics/meshlab/default.nix
index bee1e35ec129..32d528831539 100644
--- a/pkgs/applications/graphics/meshlab/default.nix
+++ b/pkgs/applications/graphics/meshlab/default.nix
@@ -86,6 +86,7 @@ mkDerivation rec {
 
   meta = {
     description = "A system for processing and editing 3D triangular meshes";
+    mainProgram = "meshlab";
     homepage = "https://www.meshlab.net/";
     license = lib.licenses.gpl3Only;
     maintainers = with lib.maintainers; [ viric ];
diff --git a/pkgs/applications/graphics/oculante/default.nix b/pkgs/applications/graphics/oculante/default.nix
index d6f8c1d641cb..f83184a488aa 100644
--- a/pkgs/applications/graphics/oculante/default.nix
+++ b/pkgs/applications/graphics/oculante/default.nix
@@ -22,16 +22,16 @@
 
 rustPlatform.buildRustPackage rec {
   pname = "oculante";
-  version = "0.8.13";
+  version = "0.8.16";
 
   src = fetchFromGitHub {
     owner = "woelper";
     repo = "oculante";
     rev = version;
-    hash = "sha256-RbRvV3OkRZXc0n7qGzqbBtbU81wFc+/Ohg9pbVqdsw4=";
+    hash = "sha256-C8USTDW5C+mjj/fr242is/42RpmUvcK3lUeaq0/BSGA=";
   };
 
-  cargoHash = "sha256-qt4bHCHpiP6yOce9hquVVlLFF906ADwhss4xAP9E0fA=";
+  cargoHash = "sha256-w8k0QG509PRHHB1e4WThYnM6R0PwWMbSBxs2B0zQ0ww=";
 
   nativeBuildInputs = [
     cmake
diff --git a/pkgs/applications/graphics/opentoonz/default.nix b/pkgs/applications/graphics/opentoonz/default.nix
index 7fd9606f3abc..1dd460c2e1d2 100644
--- a/pkgs/applications/graphics/opentoonz/default.nix
+++ b/pkgs/applications/graphics/opentoonz/default.nix
@@ -1,12 +1,93 @@
-{ boost, cmake, fetchFromGitHub, freeglut, freetype, glew, libjpeg, libmypaint
-, libpng, libtiff, libusb1, lz4, xz, lzo, openblas, opencv, pkg-config, qtbase
-, qtmultimedia, qtscript, qtserialport, lib, stdenv, superlu, wrapQtAppsHook, }:
-let source = import ./source.nix { inherit fetchFromGitHub; };
-in stdenv.mkDerivation rec {
-  inherit (source) src;
+{ boost
+, cmake
+, fetchFromGitHub
+, freeglut
+, freetype
+, glew
+, libjpeg
+, libmypaint
+, libpng
+, libusb1
+, lz4
+, xz
+, lzo
+, openblas
+, opencv
+, pkg-config
+, qtbase
+, qtmultimedia
+, qtscript
+, qtserialport
+, lib
+, stdenv
+, superlu
+, wrapQtAppsHook
+, libtiff
+, zlib
+}:
+let
+  libtiff-ver = "4.0.3"; # The version in thirdparty/tiff-*
+  opentoonz-ver = "1.7.1";
+
+  src = fetchFromGitHub {
+    owner = "opentoonz";
+    repo = "opentoonz";
+    rev = "v${opentoonz-ver}";
+    hash = "sha256-5iXOvh4QTv+G0fjEHU62u7QCee+jbvKhK0+fQXbdJis=";
+  };
+
+  opentoonz-opencv = opencv.override {
+    inherit libtiff;
+  };
+
+  opentoonz-libtiff = stdenv.mkDerivation {
+    pname = "libtiff";
+    version = "${libtiff-ver}-opentoonz";
+
+    inherit src;
+    outputs = [ "bin" "dev" "out" "man" "doc" ];
+
+    nativeBuildInputs = [ pkg-config ];
+    propagatedBuildInputs = [ zlib libjpeg xz ];
+
+    postUnpack = ''
+      sourceRoot="$sourceRoot/thirdparty/tiff-${libtiff-ver}"
+    '';
+
+    # opentoonz uses internal libtiff headers
+    postInstall = ''
+      cp libtiff/{tif_config,tif_dir,tiffiop}.h $dev/include
+    '';
+
+    meta = libtiff.meta // {
+      knownVulnerabilities = [
+        ''
+          Do not open untrusted files with Opentoonz:
+          Opentoonz uses an old custom fork of tibtiff from 2012 that is known to
+          be affected by at least these 50 vulnerabilities:
+            CVE-2012-4564 CVE-2013-4232 CVE-2013-4243 CVE-2013-4244 CVE-2014-8127
+            CVE-2014-8128 CVE-2014-8129 CVE-2014-8130 CVE-2014-9330 CVE-2015-1547
+            CVE-2015-8781 CVE-2015-8782 CVE-2015-8783 CVE-2015-8784 CVE-2015-8870
+            CVE-2016-3620 CVE-2016-3621 CVE-2016-3623 CVE-2016-3624 CVE-2016-3625
+            CVE-2016-3631 CVE-2016-3632 CVE-2016-3633 CVE-2016-3634 CVE-2016-3658
+            CVE-2016-3945 CVE-2016-3990 CVE-2016-3991 CVE-2016-5102 CVE-2016-5314
+            CVE-2016-5315 CVE-2016-5316 CVE-2016-5318 CVE-2016-5319 CVE-2016-5321
+            CVE-2016-5322 CVE-2016-5323 CVE-2016-6223 CVE-2016-9453 CVE-2016-9532
+            CVE-2017-9935 CVE-2017-9937 CVE-2018-10963 CVE-2018-5360
+            CVE-2019-14973 CVE-2019-17546 CVE-2020-35521 CVE-2020-35522
+            CVE-2020-35523 CVE-2020-35524
+          More info at https://github.com/opentoonz/opentoonz/issues/4193
+        ''
+      ];
+      maintainers = with lib.maintainers; [ chkno ];
+    };
+  };
+in
+stdenv.mkDerivation {
+  inherit src;
 
   pname = "opentoonz";
-  version = source.versions.opentoonz;
+  version = opentoonz-ver;
 
   nativeBuildInputs = [ cmake pkg-config wrapQtAppsHook ];
 
@@ -18,13 +99,13 @@ in stdenv.mkDerivation rec {
     libjpeg
     libmypaint
     libpng
-    libtiff
+    opentoonz-libtiff
     libusb1
     lz4
     xz
     lzo
     openblas
-    opencv
+    opentoonz-opencv
     qtbase
     qtmultimedia
     qtscript
@@ -36,8 +117,10 @@ in stdenv.mkDerivation rec {
 
   cmakeDir = "../sources";
   cmakeFlags = [
-    "-DTIFF_INCLUDE_DIR=${libtiff.dev}/include"
-    "-DTIFF_LIBRARY=${libtiff.out}/lib/libtiff.so"
+    "-DCMAKE_SKIP_BUILD_RPATH=ON"
+    "-DTIFF_INCLUDE_DIR=${opentoonz-libtiff.dev}/include"
+    "-DTIFF_LIBRARY=${opentoonz-libtiff.out}/lib/libtiff.so"
+    (lib.cmakeBool "CMAKE_SKIP_BUILD_RPATH" true)
   ];
 
   postInstall = ''
diff --git a/pkgs/applications/graphics/opentoonz/libtiff.nix b/pkgs/applications/graphics/opentoonz/libtiff.nix
deleted file mode 100644
index 43ba1592ccc2..000000000000
--- a/pkgs/applications/graphics/opentoonz/libtiff.nix
+++ /dev/null
@@ -1,56 +0,0 @@
-# Per https://github.com/opentoonz/opentoonz/blob/master/doc/how_to_build_linux.md ,
-# opentoonz requires its own modified version of libtiff.  We still build it as
-# a separate package
-#  1. For visibility for tools like vulnix, and
-#  2. To avoid a diamond-dependency problem with opencv linking the normal libtiff
-#     and opentoonz linking opencv and this modified libtiff, we build an opencv
-#     against this modified libtiff as well.
-#
-# We use a separate mkDerivation rather than a minimal libtiff.overrideAttrs
-# because the main libtiff builds with cmake and this version of libtiff was
-# forked before libtiff gained CMake build capability (added in libtiff-4.0.5).
-
-{ lib, fetchFromGitHub, stdenv, pkg-config, zlib, libjpeg, xz, libtiff, }:
-
-let source = import ./source.nix { inherit fetchFromGitHub; };
-
-in stdenv.mkDerivation {
-  pname = "libtiff";
-  version = source.versions.libtiff + "-opentoonz";
-
-  inherit (source) src;
-  outputs = [ "bin" "dev" "out" "man" "doc" ];
-
-  nativeBuildInputs = [ pkg-config ];
-  propagatedBuildInputs = [ zlib libjpeg xz ];
-
-  postUnpack = ''
-    sourceRoot="$sourceRoot/thirdparty/tiff-${source.versions.libtiff}"
-  '';
-
-  # opentoonz uses internal libtiff headers
-  postInstall = ''
-    cp libtiff/{tif_config,tif_dir,tiffiop}.h $dev/include
-  '';
-
-  meta = libtiff.meta // {
-    knownVulnerabilities = [''
-      Do not open untrusted files with Opentoonz:
-      Opentoonz uses an old custom fork of tibtiff from 2012 that is known to
-      be affected by at least these 50 vulnerabilities:
-        CVE-2012-4564 CVE-2013-4232 CVE-2013-4243 CVE-2013-4244 CVE-2014-8127
-        CVE-2014-8128 CVE-2014-8129 CVE-2014-8130 CVE-2014-9330 CVE-2015-1547
-        CVE-2015-8781 CVE-2015-8782 CVE-2015-8783 CVE-2015-8784 CVE-2015-8870
-        CVE-2016-3620 CVE-2016-3621 CVE-2016-3623 CVE-2016-3624 CVE-2016-3625
-        CVE-2016-3631 CVE-2016-3632 CVE-2016-3633 CVE-2016-3634 CVE-2016-3658
-        CVE-2016-3945 CVE-2016-3990 CVE-2016-3991 CVE-2016-5102 CVE-2016-5314
-        CVE-2016-5315 CVE-2016-5316 CVE-2016-5318 CVE-2016-5319 CVE-2016-5321
-        CVE-2016-5322 CVE-2016-5323 CVE-2016-6223 CVE-2016-9453 CVE-2016-9532
-        CVE-2017-9935 CVE-2017-9937 CVE-2018-10963 CVE-2018-5360
-        CVE-2019-14973 CVE-2019-17546 CVE-2020-35521 CVE-2020-35522
-        CVE-2020-35523 CVE-2020-35524
-      More info at https://github.com/opentoonz/opentoonz/issues/4193
-    ''];
-    maintainers = with lib.maintainers; [ chkno ];
-  };
-}
diff --git a/pkgs/applications/graphics/opentoonz/source.nix b/pkgs/applications/graphics/opentoonz/source.nix
deleted file mode 100644
index 27a4b8c0b0d2..000000000000
--- a/pkgs/applications/graphics/opentoonz/source.nix
+++ /dev/null
@@ -1,16 +0,0 @@
-# opentoonz's source archive contains both opentoonz's source and a modified
-# version of libtiff that opentoonz requires.
-
-{ fetchFromGitHub, }: rec {
-  versions = {
-    opentoonz = "1.5.0";
-    libtiff = "4.0.3";  # The version in thirdparty/tiff-*
-  };
-
-  src = fetchFromGitHub {
-    owner = "opentoonz";
-    repo = "opentoonz";
-    rev = "v${versions.opentoonz}";
-    sha256 = "1rw30ksw3zjph1cwxkfvqj0330v8wd4333gn0fdf3cln1w0549lk";
-  };
-}
diff --git a/pkgs/applications/graphics/ovito/default.nix b/pkgs/applications/graphics/ovito/default.nix
index 596ae0d07a11..81ce2518cea7 100644
--- a/pkgs/applications/graphics/ovito/default.nix
+++ b/pkgs/applications/graphics/ovito/default.nix
@@ -54,6 +54,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "Scientific visualization and analysis software for atomistic and particle simulation data";
+    mainProgram = "ovito";
     homepage = "https://ovito.org";
     license = with licenses;  [ gpl3Only mit ];
     maintainers = with maintainers; [ twhitehead ];
diff --git a/pkgs/applications/graphics/paleta/default.nix b/pkgs/applications/graphics/paleta/default.nix
index 062c157c3f02..6275b3d10e4c 100644
--- a/pkgs/applications/graphics/paleta/default.nix
+++ b/pkgs/applications/graphics/paleta/default.nix
@@ -52,6 +52,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Extract the dominant colors from any image";
+    mainProgram = "paleta";
     homepage = "https://github.com/nate-xyz/paleta";
     license = licenses.gpl3Only;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/pencil/default.nix b/pkgs/applications/graphics/pencil/default.nix
index ffd31bf7325a..9924e0b58c14 100644
--- a/pkgs/applications/graphics/pencil/default.nix
+++ b/pkgs/applications/graphics/pencil/default.nix
@@ -98,6 +98,7 @@ in stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "GUI prototyping/mockup tool";
+    mainProgram = "pencil";
     homepage    = "https://pencil.evolus.vn/";
     sourceProvenance = with sourceTypes; [ binaryNativeCode ];
     license     = licenses.gpl2; # Commercial license is also available
diff --git a/pkgs/applications/graphics/photoflare/default.nix b/pkgs/applications/graphics/photoflare/default.nix
index 6c6ea1059c73..3f47a0073d24 100644
--- a/pkgs/applications/graphics/photoflare/default.nix
+++ b/pkgs/applications/graphics/photoflare/default.nix
@@ -21,6 +21,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "A cross-platform image editor with a powerful features and a very friendly graphical user interface";
+    mainProgram = "photoflare";
     homepage = "https://photoflare.io";
     maintainers = [ maintainers.omgbebebe ];
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/photoqt/default.nix b/pkgs/applications/graphics/photoqt/default.nix
index 5d1ce4129791..ccc95ac94216 100644
--- a/pkgs/applications/graphics/photoqt/default.nix
+++ b/pkgs/applications/graphics/photoqt/default.nix
@@ -20,16 +20,17 @@
 , qtmultimedia
 , qtpositioning
 , qtsvg
+, zxing-cpp
 , qtwayland
 }:
 
 stdenv.mkDerivation rec {
   pname = "photoqt";
-  version = "4.2";
+  version = "4.3";
 
   src = fetchurl {
     url = "https://photoqt.org/pkgs/photoqt-${version}.tar.gz";
-    hash = "sha256-OUqsyvmv6ccJDzcWAeS1OOmK2eXOCEgGktz6GEUzoA8=";
+    hash = "sha256-B0ZubvWIEZFnD2v74bpPv+/wr7vaHS9QP4//9/afjzQ=";
   };
 
   nativeBuildInputs = [
@@ -55,20 +56,19 @@ stdenv.mkDerivation rec {
     qtmultimedia
     qtpositioning
     qtsvg
+    zxing-cpp
   ] ++ lib.optionals stdenv.isLinux [
     qtwayland
   ];
 
   cmakeFlags = [
-    "-DDEVIL=OFF"
-    "-DCHROMECAST=OFF"
-    "-DFREEIMAGE=OFF"
-    "-DIMAGEMAGICK=OFF"
+    (lib.cmakeBool "DEVIL" false)
+    (lib.cmakeBool "CHROMECAST" false)
+    (lib.cmakeBool "FREEIMAGE" false)
+    (lib.cmakeBool "IMAGEMAGICK" false)
   ];
 
-  preConfigure = ''
-    export MAGICK_LOCATION="${graphicsmagick}/include/GraphicsMagick"
-  '';
+  env.MAGICK_LOCATION = "${graphicsmagick}/include/GraphicsMagick";
 
   postInstall = lib.optionalString stdenv.isDarwin ''
     mkdir -p $out/Applications
diff --git a/pkgs/applications/graphics/phototonic/default.nix b/pkgs/applications/graphics/phototonic/default.nix
index 738f78cf347d..345398435a07 100644
--- a/pkgs/applications/graphics/phototonic/default.nix
+++ b/pkgs/applications/graphics/phototonic/default.nix
@@ -28,6 +28,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "An image viewer and organizer";
+    mainProgram = "phototonic";
     homepage = "https://github.com/oferkv/phototonic";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ pSub ];
diff --git a/pkgs/applications/graphics/pick-colour-picker/default.nix b/pkgs/applications/graphics/pick-colour-picker/default.nix
index a4b8bbc9c2fd..bd9ab649d633 100644
--- a/pkgs/applications/graphics/pick-colour-picker/default.nix
+++ b/pkgs/applications/graphics/pick-colour-picker/default.nix
@@ -47,6 +47,7 @@ buildPythonPackage rec {
     license = licenses.mit;
     platforms = platforms.linux;
     description = "A colour picker that remembers where you picked colours from";
+    mainProgram = "pick-colour-picker";
     maintainers = [ maintainers.mkg20001 ];
 
     longDescription = ''
diff --git a/pkgs/applications/graphics/pikopixel/default.nix b/pkgs/applications/graphics/pikopixel/default.nix
index f8719cc0a4cd..c65353143368 100644
--- a/pkgs/applications/graphics/pikopixel/default.nix
+++ b/pkgs/applications/graphics/pikopixel/default.nix
@@ -39,9 +39,10 @@ clangStdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Application for drawing and editing pixel-art images";
+    mainProgram = "PikoPixel";
     homepage = "https://twilightedge.com/mac/pikopixel/";
     downloadPage = "https://twilightedge.com/mac/pikopixel/";
-    license = licenses.agpl3;
+    license = licenses.agpl3Plus;
     maintainers = with maintainers; [ fgaz ];
     platforms = platforms.all;
   };
diff --git a/pkgs/applications/graphics/pizarra/default.nix b/pkgs/applications/graphics/pizarra/default.nix
index f9d7fc650647..b53368439d75 100644
--- a/pkgs/applications/graphics/pizarra/default.nix
+++ b/pkgs/applications/graphics/pizarra/default.nix
@@ -41,6 +41,7 @@ rustPlatform.buildRustPackage rec {
 
   meta = with lib; {
     description = "A simple blackboard written in GTK";
+    mainProgram = "pizarra";
     longDescription = ''
       A simple endless blackboard.
       Contains various features, such as:
diff --git a/pkgs/applications/graphics/qcomicbook/default.nix b/pkgs/applications/graphics/qcomicbook/default.nix
index 47bf2d950283..ee2296b391bb 100644
--- a/pkgs/applications/graphics/qcomicbook/default.nix
+++ b/pkgs/applications/graphics/qcomicbook/default.nix
@@ -27,6 +27,7 @@ mkDerivation rec {
   meta = with lib; {
     homepage = "https://github.com/stolowski/QComicBook";
     description = "Comic book reader in Qt5";
+    mainProgram = "qcomicbook";
     license = licenses.gpl2;
 
     longDescription = ''
diff --git a/pkgs/applications/graphics/qimgv/default.nix b/pkgs/applications/graphics/qimgv/default.nix
index 2cb5f8ddde24..c6789fd05738 100644
--- a/pkgs/applications/graphics/qimgv/default.nix
+++ b/pkgs/applications/graphics/qimgv/default.nix
@@ -55,6 +55,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "A Qt5 image viewer with optional video support";
+    mainProgram = "qimgv";
     homepage = "https://github.com/easymodo/qimgv";
     license = licenses.gpl3;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/qosmic/default.nix b/pkgs/applications/graphics/qosmic/default.nix
index 9e2248f896de..a3a688fd0366 100644
--- a/pkgs/applications/graphics/qosmic/default.nix
+++ b/pkgs/applications/graphics/qosmic/default.nix
@@ -72,6 +72,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A cosmic recursive flame fractal editor";
+    mainProgram = "qosmic";
     homepage = "https://github.com/bitsed/qosmic";
     license = licenses.gpl3Plus;
     maintainers = [ maintainers.raboof ];
diff --git a/pkgs/applications/graphics/qscreenshot/default.nix b/pkgs/applications/graphics/qscreenshot/default.nix
index efbab2e04bbb..761bd69d3520 100644
--- a/pkgs/applications/graphics/qscreenshot/default.nix
+++ b/pkgs/applications/graphics/qscreenshot/default.nix
@@ -31,6 +31,7 @@ stdenv.mkDerivation rec {
   ];
   meta = with lib; {
     description = "Simple creation and editing of screenshots";
+    mainProgram = "qScreenshot";
     homepage = "https://sourceforge.net/projects/qscreenshot/";
     license = licenses.gpl2;
     platforms = platforms.all;
diff --git a/pkgs/applications/graphics/qvge/default.nix b/pkgs/applications/graphics/qvge/default.nix
index 442e3200e469..e7c6def43b91 100644
--- a/pkgs/applications/graphics/qvge/default.nix
+++ b/pkgs/applications/graphics/qvge/default.nix
@@ -33,6 +33,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Qt Visual Graph Editor";
+    mainProgram = "qvgeapp";
     homepage = "https://github.com/ArsMasiuk/qvge";
     license = licenses.mit;
     maintainers = with maintainers; [ sikmir ];
diff --git a/pkgs/applications/graphics/qview/default.nix b/pkgs/applications/graphics/qview/default.nix
index 9bba92a2b5b7..38ff606487c0 100644
--- a/pkgs/applications/graphics/qview/default.nix
+++ b/pkgs/applications/graphics/qview/default.nix
@@ -34,6 +34,7 @@ mkDerivation rec {
 
   meta = with lib; {
     description = "Practical and minimal image viewer";
+    mainProgram = "qview";
     homepage = "https://interversehq.com/qview/";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ acowley ];
diff --git a/pkgs/applications/graphics/rapid-photo-downloader/default.nix b/pkgs/applications/graphics/rapid-photo-downloader/default.nix
index e6d0319950d5..494815ac930b 100644
--- a/pkgs/applications/graphics/rapid-photo-downloader/default.nix
+++ b/pkgs/applications/graphics/rapid-photo-downloader/default.nix
@@ -97,6 +97,7 @@ mkDerivationWith python3Packages.buildPythonApplication rec {
 
   meta = with lib; {
     description = "Photo and video importer for cameras, phones, and memory cards";
+    mainProgram = "rapid-photo-downloader";
     homepage = "https://www.damonlynch.net/rapid/";
     license = licenses.gpl3Plus;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/rx/default.nix b/pkgs/applications/graphics/rx/default.nix
index fe3d10bae635..77ed3f49117c 100644
--- a/pkgs/applications/graphics/rx/default.nix
+++ b/pkgs/applications/graphics/rx/default.nix
@@ -37,6 +37,7 @@ rustPlatform.buildRustPackage rec {
 
   meta = {
     description = "Modern and extensible pixel editor implemented in Rust";
+    mainProgram = "rx";
     homepage = "https://rx.cloudhead.io/";
     license = licenses.gpl3;
     maintainers = with maintainers; [ minijackson Br1ght0ne ];
diff --git a/pkgs/applications/graphics/sane/backends/airscan/default.nix b/pkgs/applications/graphics/sane/backends/airscan/default.nix
index d88c7352d574..83530518aa7d 100644
--- a/pkgs/applications/graphics/sane/backends/airscan/default.nix
+++ b/pkgs/applications/graphics/sane/backends/airscan/default.nix
@@ -1,22 +1,23 @@
-{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, avahi, libjpeg, libpng
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkg-config, avahi, libjpeg, libpng, libtiff
 , libxml2, gnutls, sane-backends }:
 stdenv.mkDerivation rec {
   pname = "sane-airscan";
-  version = "0.99.27";
+  version = "0.99.29";
 
   nativeBuildInputs = [ meson ninja pkg-config ];
-  buildInputs = [ avahi gnutls libjpeg libpng libxml2 sane-backends ];
+  buildInputs = [ avahi gnutls libjpeg libpng libxml2 libtiff sane-backends ];
 
   src = fetchFromGitHub {
     owner = "alexpevzner";
     repo = pname;
     rev = version;
-    sha256 = "sha256-29IPoLF4rmq8sGTi5RmpT1Fq8RJJlaepTt+2GWDU3es=";
+    sha256 = "sha256-9ErTC9NztyO9o6y2FjQPl2lu1gICasZYm2tnaCVCLt8=";
   };
 
   meta = with lib; {
     homepage = "https://github.com/alexpevzner/sane-airscan";
     description = "Scanner Access Now Easy - Apple AirScan (eSCL) driver";
+    mainProgram = "airscan-discover";
     longDescription = ''
       sane-airscan: Linux support of Apple AirScan (eSCL) compatible document scanners.
     '';
diff --git a/pkgs/applications/graphics/sane/xsane.nix b/pkgs/applications/graphics/sane/xsane.nix
index 471e2141b5b8..e9a1ca2c40de 100644
--- a/pkgs/applications/graphics/sane/xsane.nix
+++ b/pkgs/applications/graphics/sane/xsane.nix
@@ -48,6 +48,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "http://www.sane-project.org/";
     description = "Graphical scanning frontend for sane";
+    mainProgram = "xsane";
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
     maintainers = with maintainers; [ melling ];
diff --git a/pkgs/applications/graphics/scantailor/advanced.nix b/pkgs/applications/graphics/scantailor/advanced.nix
index 2ab5c5562670..b83b9df83b01 100644
--- a/pkgs/applications/graphics/scantailor/advanced.nix
+++ b/pkgs/applications/graphics/scantailor/advanced.nix
@@ -19,6 +19,7 @@ mkDerivation rec {
   meta = with lib; {
     homepage = "https://github.com/vigri/scantailor-advanced";
     description = "Interactive post-processing tool for scanned pages (vigri's fork)";
+    mainProgram = "scantailor";
     license = licenses.gpl3Plus;
     maintainers = with maintainers; [ ];
     platforms = with platforms; gnu ++ linux ++ darwin;
diff --git a/pkgs/applications/graphics/shotwell/default.nix b/pkgs/applications/graphics/shotwell/default.nix
index 9eb1fbb28ee4..e6d6eb41b9e0 100644
--- a/pkgs/applications/graphics/shotwell/default.nix
+++ b/pkgs/applications/graphics/shotwell/default.nix
@@ -96,6 +96,7 @@ stdenv.mkDerivation (finalAttrs: {
 
   meta = with lib; {
     description = "Popular photo organizer for the GNOME desktop";
+    mainProgram = "shotwell";
     homepage = "https://wiki.gnome.org/Apps/Shotwell";
     license = licenses.lgpl21Plus;
     maintainers = with maintainers; [];
diff --git a/pkgs/applications/graphics/shutter/default.nix b/pkgs/applications/graphics/shutter/default.nix
index e5659fb7fe2a..d10e8487796f 100644
--- a/pkgs/applications/graphics/shutter/default.nix
+++ b/pkgs/applications/graphics/shutter/default.nix
@@ -104,6 +104,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Screenshot and annotation tool";
+    mainProgram = "shutter";
     homepage = "https://shutter-project.org/";
     license = licenses.gpl3Plus;
     platforms = platforms.all;
diff --git a/pkgs/applications/graphics/smartdeblur/default.nix b/pkgs/applications/graphics/smartdeblur/default.nix
index 51c0f306f92d..592244455e98 100644
--- a/pkgs/applications/graphics/smartdeblur/default.nix
+++ b/pkgs/applications/graphics/smartdeblur/default.nix
@@ -28,6 +28,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://github.com/Y-Vladimir/SmartDeblur";
     description = "Tool for restoring blurry and defocused images";
+    mainProgram = "SmartDeblur";
     license = licenses.gpl3;
     maintainers = with maintainers; [ ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/structorizer/default.nix b/pkgs/applications/graphics/structorizer/default.nix
index bb6d2660836a..6bf2cf24d80e 100644
--- a/pkgs/applications/graphics/structorizer/default.nix
+++ b/pkgs/applications/graphics/structorizer/default.nix
@@ -10,7 +10,7 @@
 
 stdenv.mkDerivation rec {
   pname = "structorizer";
-  version = "3.32-16";
+  version = "3.32-18";
 
   desktopItems = [
     (makeDesktopItem {
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     owner = "fesch";
     repo = "Structorizer.Desktop";
     rev = version;
-    hash = "sha256-K/ofwwlkZF13V0IZEL166n58ylm+qdh1jbXzH7LwXog=";
+    hash = "sha256-CA87j11TFUd0nmuPc1qyqdITkTPE/jauf31cO2iBQVg=";
   };
 
   patches = [ ./makeStructorizer.patch ./makeBigJar.patch ];
diff --git a/pkgs/applications/graphics/symbolic-preview/default.nix b/pkgs/applications/graphics/symbolic-preview/default.nix
index b73d481966b1..6f3103ecb8a6 100644
--- a/pkgs/applications/graphics/symbolic-preview/default.nix
+++ b/pkgs/applications/graphics/symbolic-preview/default.nix
@@ -20,6 +20,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://gitlab.gnome.org/World/design/symbolic-preview";
     description = "Symbolics made easy";
+    mainProgram = "symbolic-preview";
     maintainers = with maintainers; [ qyliss ];
     license = licenses.gpl3Plus;
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/tev/default.nix b/pkgs/applications/graphics/tev/default.nix
index ff97eb65f17c..ca70027eb202 100644
--- a/pkgs/applications/graphics/tev/default.nix
+++ b/pkgs/applications/graphics/tev/default.nix
@@ -35,6 +35,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A high dynamic range (HDR) image comparison tool";
+    mainProgram = "tev";
     longDescription = ''
       A high dynamic range (HDR) image comparison tool for graphics people. tev
       allows viewing images through various tonemapping operators and inspecting
diff --git a/pkgs/applications/graphics/timelapse-deflicker/default.nix b/pkgs/applications/graphics/timelapse-deflicker/default.nix
index f1757d51b1b3..511ed8a0134a 100644
--- a/pkgs/applications/graphics/timelapse-deflicker/default.nix
+++ b/pkgs/applications/graphics/timelapse-deflicker/default.nix
@@ -25,6 +25,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "Simple script to deflicker images taken for timelapses";
+    mainProgram = "timelapse-deflicker";
     homepage = "https://github.com/cyberang3l/timelapse-deflicker";
     license = licenses.gpl3;
     maintainers = with maintainers; [ valeriangalliat ];
diff --git a/pkgs/applications/graphics/vengi-tools/default.nix b/pkgs/applications/graphics/vengi-tools/default.nix
index 771ae49e220d..1c3bf8b6ede3 100644
--- a/pkgs/applications/graphics/vengi-tools/default.nix
+++ b/pkgs/applications/graphics/vengi-tools/default.nix
@@ -29,13 +29,13 @@
 
 stdenv.mkDerivation (finalAttrs: {
   pname = "vengi-tools";
-  version = "0.0.28";
+  version = "0.0.29";
 
   src = fetchFromGitHub {
     owner = "mgerhardy";
     repo = "vengi";
     rev = "v${finalAttrs.version}";
-    hash = "sha256-UjSm/J/y7MUg3Exmw0P56+bcjiLxXdGS2brocdzgJ+c=";
+    hash = "sha256-VGgmJPNLEsD1y6e6CRw1Wipmy9MKAQkydyHNNjPyvhQ=";
   };
 
   nativeBuildInputs = [
diff --git a/pkgs/applications/graphics/vengi-tools/test-voxconvert-all-formats.nix b/pkgs/applications/graphics/vengi-tools/test-voxconvert-all-formats.nix
index fc99ceb07144..c3e6e47adfba 100644
--- a/pkgs/applications/graphics/vengi-tools/test-voxconvert-all-formats.nix
+++ b/pkgs/applications/graphics/vengi-tools/test-voxconvert-all-formats.nix
@@ -9,7 +9,7 @@ stdenv.mkDerivation {
     mkdir $out
     for format in vox qef qbt qb vxm vxr binvox gox cub vxl csv; do
       echo Testing $format export
-      ${vengi-tools}/bin/vengi-voxconvert --input ${vengi-tools.src}/data/voxedit/chr_knight.qb --output $out/chr_knight.$format
+      ${vengi-tools}/bin/vengi-voxconvert --input ${vengi-tools.src}/data/tests/chr_knight.qb --output $out/chr_knight.$format
     done
   '';
 }
diff --git a/pkgs/applications/graphics/vengi-tools/test-voxconvert-roundtrip.nix b/pkgs/applications/graphics/vengi-tools/test-voxconvert-roundtrip.nix
index a6fbb65fedfd..a683bff7a10b 100644
--- a/pkgs/applications/graphics/vengi-tools/test-voxconvert-roundtrip.nix
+++ b/pkgs/applications/graphics/vengi-tools/test-voxconvert-roundtrip.nix
@@ -6,7 +6,7 @@ stdenv.mkDerivation {
   name = "vengi-tools-test-voxconvert-roundtrip";
   meta.timeout = 10;
   buildCommand = ''
-    ${vengi-tools}/bin/vengi-voxconvert --input ${vengi-tools.src}/data/voxedit/chr_knight.qb --output chr_knight.vox
+    ${vengi-tools}/bin/vengi-voxconvert --input ${vengi-tools.src}/data/tests/chr_knight.qb --output chr_knight.vox
     ${vengi-tools}/bin/vengi-voxconvert --input chr_knight.vox --output chr_knight.qb
     ${vengi-tools}/bin/vengi-voxconvert --input chr_knight.qb --output chr_knight1.vox
     diff chr_knight.vox chr_knight1.vox
diff --git a/pkgs/applications/graphics/veusz/default.nix b/pkgs/applications/graphics/veusz/default.nix
index d630ceda6a58..67f5a76e5e97 100644
--- a/pkgs/applications/graphics/veusz/default.nix
+++ b/pkgs/applications/graphics/veusz/default.nix
@@ -62,6 +62,7 @@ python3Packages.buildPythonApplication rec {
 
   meta = with lib; {
     description = "A scientific plotting and graphing program with a GUI";
+    mainProgram = "veusz";
     homepage = "https://veusz.github.io/";
     license = licenses.gpl2Plus;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/weylus/default.nix b/pkgs/applications/graphics/weylus/default.nix
index 27021eab2132..36647a62aef2 100644
--- a/pkgs/applications/graphics/weylus/default.nix
+++ b/pkgs/applications/graphics/weylus/default.nix
@@ -99,6 +99,7 @@ rustPlatform.buildRustPackage rec {
   meta = with lib; {
     broken = stdenv.isDarwin;
     description = "Use your tablet as graphic tablet/touch screen on your computer";
+    mainProgram = "weylus";
     homepage = "https://github.com/H-M-H/Weylus";
     license = with licenses; [ agpl3Only ];
     maintainers = with maintainers; [ lom ];
diff --git a/pkgs/applications/graphics/xaos/default.nix b/pkgs/applications/graphics/xaos/default.nix
index e79f322be5e4..dd717223fdbb 100644
--- a/pkgs/applications/graphics/xaos/default.nix
+++ b/pkgs/applications/graphics/xaos/default.nix
@@ -42,6 +42,7 @@ in stdenv.mkDerivation rec {
 
   meta = src.meta // {
     description = "Real-time interactive fractal zoomer";
+    mainProgram = "xaos";
     homepage = "https://xaos-project.github.io/";
     license = lib.licenses.gpl2Plus;
     platforms = [ "x86_64-linux" ];
diff --git a/pkgs/applications/graphics/xfig/default.nix b/pkgs/applications/graphics/xfig/default.nix
index 00e736731f2f..cb96daeb1270 100644
--- a/pkgs/applications/graphics/xfig/default.nix
+++ b/pkgs/applications/graphics/xfig/default.nix
@@ -61,6 +61,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     changelog = "https://sourceforge.net/p/mcj/xfig/ci/${version}/tree/CHANGES";
     description = "An interactive drawing tool for X11";
+    mainProgram = "xfig";
     longDescription = ''
       Note that you need to have the <literal>netpbm</literal> tools
       in your path to export bitmaps.
diff --git a/pkgs/applications/graphics/xpano/default.nix b/pkgs/applications/graphics/xpano/default.nix
index 3ba27e66e66f..9842aca43dd8 100644
--- a/pkgs/applications/graphics/xpano/default.nix
+++ b/pkgs/applications/graphics/xpano/default.nix
@@ -53,6 +53,7 @@ stdenv.mkDerivation rec {
 
   meta = with lib; {
     description = "A panorama stitching tool";
+    mainProgram = "Xpano";
     homepage = "https://krupkat.github.io/xpano/";
     changelog = "https://github.com/krupkat/xpano/releases/tag/v${version}";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/xrgears/default.nix b/pkgs/applications/graphics/xrgears/default.nix
index ac73412117cf..2f367e8a70d5 100644
--- a/pkgs/applications/graphics/xrgears/default.nix
+++ b/pkgs/applications/graphics/xrgears/default.nix
@@ -52,6 +52,7 @@ stdenv.mkDerivation rec {
   meta = with lib; {
     homepage = "https://gitlab.freedesktop.org/monado/demos/xrgears";
     description = "An OpenXR example using Vulkan for rendering";
+    mainProgram = "xrgears";
     platforms = platforms.linux;
     license = licenses.mit;
     maintainers = with maintainers; [ expipiplus1 ];