about summary refs log tree commit diff
path: root/pkgs/applications/graphics
diff options
context:
space:
mode:
authorProfpatsch <mail@profpatsch.de>2021-01-11 08:54:33 +0100
committerProfpatsch <mail@profpatsch.de>2021-01-11 10:38:22 +0100
commit4a7f99d55d299453a9c2397f90b33d1120669775 (patch)
tree9fca8e9c9970d0a00ce56dfe11b63ae76b00cf01 /pkgs/applications/graphics
parente87aef06e00c42b26789321454d7bd609548cc12 (diff)
downloadnixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar.gz
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar.bz2
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar.lz
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar.xz
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.tar.zst
nixlib-4a7f99d55d299453a9c2397f90b33d1120669775.zip
treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
Diffstat (limited to 'pkgs/applications/graphics')
-rw-r--r--pkgs/applications/graphics/ImageMagick/7.0.nix2
-rw-r--r--pkgs/applications/graphics/ImageMagick/default.nix2
-rw-r--r--pkgs/applications/graphics/ahoviewer/default.nix4
-rw-r--r--pkgs/applications/graphics/alchemy/default.nix4
-rw-r--r--pkgs/applications/graphics/antimony/default.nix4
-rw-r--r--pkgs/applications/graphics/apitrace/default.nix4
-rw-r--r--pkgs/applications/graphics/apngasm/2.nix4
-rw-r--r--pkgs/applications/graphics/apngasm/default.nix4
-rw-r--r--pkgs/applications/graphics/autotrace/default.nix4
-rw-r--r--pkgs/applications/graphics/avocode/default.nix4
-rw-r--r--pkgs/applications/graphics/azpainter/default.nix4
-rw-r--r--pkgs/applications/graphics/batik/default.nix4
-rw-r--r--pkgs/applications/graphics/c3d/default.nix4
-rw-r--r--pkgs/applications/graphics/darktable/default.nix4
-rw-r--r--pkgs/applications/graphics/deskew/default.nix4
-rw-r--r--pkgs/applications/graphics/dia/default.nix4
-rw-r--r--pkgs/applications/graphics/djview/default.nix4
-rw-r--r--pkgs/applications/graphics/drawio/default.nix2
-rw-r--r--pkgs/applications/graphics/epeg/default.nix4
-rw-r--r--pkgs/applications/graphics/exrtools/default.nix4
-rw-r--r--pkgs/applications/graphics/f3d/default.nix4
-rw-r--r--pkgs/applications/graphics/fbida/default.nix4
-rw-r--r--pkgs/applications/graphics/fig2dev/default.nix4
-rw-r--r--pkgs/applications/graphics/fluxus/default.nix4
-rw-r--r--pkgs/applications/graphics/fondo/default.nix4
-rw-r--r--pkgs/applications/graphics/freecad/default.nix4
-rw-r--r--pkgs/applications/graphics/fstl/default.nix4
-rw-r--r--pkgs/applications/graphics/gcolor3/default.nix4
-rw-r--r--pkgs/applications/graphics/geeqie/default.nix4
-rw-r--r--pkgs/applications/graphics/gimp/plugins/default.nix4
-rw-r--r--pkgs/applications/graphics/glabels/default.nix4
-rw-r--r--pkgs/applications/graphics/gnome-photos/default.nix4
-rw-r--r--pkgs/applications/graphics/gnuclad/default.nix2
-rw-r--r--pkgs/applications/graphics/goxel/default.nix4
-rw-r--r--pkgs/applications/graphics/gpicview/default.nix4
-rw-r--r--pkgs/applications/graphics/gqview/default.nix4
-rw-r--r--pkgs/applications/graphics/gthumb/default.nix4
-rw-r--r--pkgs/applications/graphics/hugin/default.nix4
-rw-r--r--pkgs/applications/graphics/hydrus/default.nix4
-rw-r--r--pkgs/applications/graphics/ideogram/default.nix4
-rw-r--r--pkgs/applications/graphics/imagej/default.nix4
-rw-r--r--pkgs/applications/graphics/imgbrd-grabber/default.nix4
-rw-r--r--pkgs/applications/graphics/imgcat/default.nix4
-rw-r--r--pkgs/applications/graphics/imlibsetroot/default.nix4
-rw-r--r--pkgs/applications/graphics/imv/default.nix2
-rw-r--r--pkgs/applications/graphics/inkscape/default.nix4
-rw-r--r--pkgs/applications/graphics/inkscape/extensions.nix4
-rw-r--r--pkgs/applications/graphics/jpeg-archive/default.nix4
-rw-r--r--pkgs/applications/graphics/jpeginfo/default.nix4
-rw-r--r--pkgs/applications/graphics/jpegoptim/default.nix4
-rw-r--r--pkgs/applications/graphics/jpegrescan/default.nix4
-rw-r--r--pkgs/applications/graphics/k3d/default.nix4
-rw-r--r--pkgs/applications/graphics/kgraphviewer/default.nix4
-rw-r--r--pkgs/applications/graphics/kodelife/default.nix4
-rw-r--r--pkgs/applications/graphics/ktikz/default.nix4
-rw-r--r--pkgs/applications/graphics/lazpaint/default.nix4
-rw-r--r--pkgs/applications/graphics/leocad/default.nix4
-rw-r--r--pkgs/applications/graphics/luminance-hdr/default.nix4
-rw-r--r--pkgs/applications/graphics/mcomix3/default.nix2
-rw-r--r--pkgs/applications/graphics/meme/default.nix4
-rw-r--r--pkgs/applications/graphics/monado/default.nix4
-rw-r--r--pkgs/applications/graphics/mypaint/default.nix4
-rw-r--r--pkgs/applications/graphics/nomacs/default.nix4
-rw-r--r--pkgs/applications/graphics/nufraw/default.nix2
-rw-r--r--pkgs/applications/graphics/ocrad/default.nix4
-rw-r--r--pkgs/applications/graphics/ocrfeeder/default.nix4
-rw-r--r--pkgs/applications/graphics/odafileconverter/default.nix2
-rw-r--r--pkgs/applications/graphics/openimageio/2.x.nix4
-rw-r--r--pkgs/applications/graphics/openimageio/default.nix4
-rw-r--r--pkgs/applications/graphics/paraview/default.nix4
-rw-r--r--pkgs/applications/graphics/pbrt/default.nix4
-rw-r--r--pkgs/applications/graphics/pdfcpu/default.nix4
-rw-r--r--pkgs/applications/graphics/pencil/default.nix2
-rw-r--r--pkgs/applications/graphics/photivo/default.nix4
-rw-r--r--pkgs/applications/graphics/photoflare/default.nix4
-rw-r--r--pkgs/applications/graphics/photoflow/default.nix4
-rw-r--r--pkgs/applications/graphics/phototonic/default.nix4
-rw-r--r--pkgs/applications/graphics/pick-colour-picker/default.nix4
-rw-r--r--pkgs/applications/graphics/potrace/default.nix4
-rw-r--r--pkgs/applications/graphics/pqiv/default.nix4
-rw-r--r--pkgs/applications/graphics/processing/default.nix4
-rw-r--r--pkgs/applications/graphics/qcomicbook/default.nix4
-rw-r--r--pkgs/applications/graphics/qiv/default.nix4
-rw-r--r--pkgs/applications/graphics/qscreenshot/default.nix4
-rw-r--r--pkgs/applications/graphics/rapcad/default.nix4
-rw-r--r--pkgs/applications/graphics/rapid-photo-downloader/default.nix4
-rw-r--r--pkgs/applications/graphics/renderdoc/default.nix4
-rw-r--r--pkgs/applications/graphics/sane/backends/generic.nix4
-rw-r--r--pkgs/applications/graphics/sane/frontends.nix4
-rw-r--r--pkgs/applications/graphics/scantailor/advanced.nix4
-rw-r--r--pkgs/applications/graphics/shotwell/default.nix4
-rw-r--r--pkgs/applications/graphics/shutter/default.nix4
-rw-r--r--pkgs/applications/graphics/solvespace/default.nix4
-rw-r--r--pkgs/applications/graphics/swingsane/default.nix4
-rw-r--r--pkgs/applications/graphics/synfigstudio/default.nix4
-rw-r--r--pkgs/applications/graphics/tev/default.nix4
-rw-r--r--pkgs/applications/graphics/timelapse-deflicker/default.nix4
-rw-r--r--pkgs/applications/graphics/ufraw/default.nix4
-rw-r--r--pkgs/applications/graphics/viewnior/default.nix4
-rw-r--r--pkgs/applications/graphics/write_stylus/default.nix2
-rw-r--r--pkgs/applications/graphics/xfig/default.nix4
-rw-r--r--pkgs/applications/graphics/xlife/default.nix4
-rw-r--r--pkgs/applications/graphics/xournal/default.nix4
-rw-r--r--pkgs/applications/graphics/xournalpp/default.nix4
-rw-r--r--pkgs/applications/graphics/xrgears/default.nix4
-rw-r--r--pkgs/applications/graphics/xzgv/default.nix4
-rw-r--r--pkgs/applications/graphics/yed/default.nix4
-rw-r--r--pkgs/applications/graphics/zgv/default.nix4
108 files changed, 206 insertions, 206 deletions
diff --git a/pkgs/applications/graphics/ImageMagick/7.0.nix b/pkgs/applications/graphics/ImageMagick/7.0.nix
index 558112763a23..9d52046ba0cb 100644
--- a/pkgs/applications/graphics/ImageMagick/7.0.nix
+++ b/pkgs/applications/graphics/ImageMagick/7.0.nix
@@ -80,7 +80,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.imagemagick.org/";
     description = "A software suite to create, edit, compose, or convert bitmap images";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/applications/graphics/ImageMagick/default.nix b/pkgs/applications/graphics/ImageMagick/default.nix
index 0222efff6429..42f157e53139 100644
--- a/pkgs/applications/graphics/ImageMagick/default.nix
+++ b/pkgs/applications/graphics/ImageMagick/default.nix
@@ -96,7 +96,7 @@ stdenv.mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.imagemagick.org/";
     description = "A software suite to create, edit, compose, or convert bitmap images";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/applications/graphics/ahoviewer/default.nix b/pkgs/applications/graphics/ahoviewer/default.nix
index c5f1bf868018..a994ae271c9c 100644
--- a/pkgs/applications/graphics/ahoviewer/default.nix
+++ b/pkgs/applications/graphics/ahoviewer/default.nix
@@ -1,4 +1,4 @@
-{ config, stdenv, fetchFromGitHub, pkgconfig, libconfig
+{ config, lib, stdenv, fetchFromGitHub, pkgconfig, libconfig
 , gtkmm2, glibmm, libxml2, libsecret, curl, libzip
 , librsvg, gst_all_1, autoreconfHook, makeWrapper
 , useUnrar ? config.ahoviewer.useUnrar or false, unrar
@@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
     --set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/ahodesuka/ahoviewer";
     description = "A GTK2 image viewer, manga reader, and booru browser";
     maintainers = with maintainers; [ skrzyp xzfc ];
diff --git a/pkgs/applications/graphics/alchemy/default.nix b/pkgs/applications/graphics/alchemy/default.nix
index 6fc84e088dd3..27d5ece57fe6 100644
--- a/pkgs/applications/graphics/alchemy/default.nix
+++ b/pkgs/applications/graphics/alchemy/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, runtimeShell }:
+{ lib, stdenv, fetchurl, jre, runtimeShell }:
 
 stdenv.mkDerivation rec {
   pname = "alchemy";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     chmod +x $out/bin/alchemy
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Drawing application";
     longDescription = ''
       Alchemy is an open drawing project aimed at exploring how we can sketch,
diff --git a/pkgs/applications/graphics/antimony/default.nix b/pkgs/applications/graphics/antimony/default.nix
index 95be29abba54..d92ad9998f2c 100644
--- a/pkgs/applications/graphics/antimony/default.nix
+++ b/pkgs/applications/graphics/antimony/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libpng, python3
+{ lib, stdenv, fetchFromGitHub, libpng, python3
 , libGLU, libGL, qtbase, wrapQtAppsHook, ncurses
 , cmake, flex, lemon
 }:
@@ -40,7 +40,7 @@ in
       "-DGITBRANCH=${gitBranch}"
     ];
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "A computer-aided design (CAD) tool from a parallel universe";
       homepage    = "https://github.com/mkeeter/antimony";
       license     = licenses.mit;
diff --git a/pkgs/applications/graphics/apitrace/default.nix b/pkgs/applications/graphics/apitrace/default.nix
index 84a005445316..462962d9e188 100644
--- a/pkgs/applications/graphics/apitrace/default.nix
+++ b/pkgs/applications/graphics/apitrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, libX11, procps, python2, libdwarf, qtbase, qtwebkit, wrapQtAppsHook, libglvnd }:
+{ lib, stdenv, fetchFromGitHub, cmake, libX11, procps, python2, libdwarf, qtbase, qtwebkit, wrapQtAppsHook, libglvnd }:
 
 stdenv.mkDerivation rec {
   pname = "apitrace";
@@ -58,7 +58,7 @@ stdenv.mkDerivation rec {
     wrapQtApp $out/bin/qapitrace
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://apitrace.github.io";
     description = "Tools to trace OpenGL, OpenGL ES, Direct3D, and DirectDraw APIs";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/apngasm/2.nix b/pkgs/applications/graphics/apngasm/2.nix
index 166bc135c193..0313115ddfa8 100644
--- a/pkgs/applications/graphics/apngasm/2.nix
+++ b/pkgs/applications/graphics/apngasm/2.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, libpng, zlib, zopfli }:
+{ lib, stdenv, fetchzip, libpng, zlib, zopfli }:
 
 stdenv.mkDerivation rec {
   pname = "apngasm";
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create highly optimized Animated PNG files from PNG/TGA images";
     homepage = "http://apngasm.sourceforge.net/";
     license = licenses.zlib;
diff --git a/pkgs/applications/graphics/apngasm/default.nix b/pkgs/applications/graphics/apngasm/default.nix
index 8d50696efcbd..1f58ee83e03a 100644
--- a/pkgs/applications/graphics/apngasm/default.nix
+++ b/pkgs/applications/graphics/apngasm/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, boost, libpng, zlib }:
+{ lib, stdenv, fetchFromGitHub, cmake, boost, libpng, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "apngasm";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ boost libpng zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create an APNG from multiple PNG files";
     homepage = "https://github.com/apngasm/apngasm";
     license = licenses.zlib;
diff --git a/pkgs/applications/graphics/autotrace/default.nix b/pkgs/applications/graphics/autotrace/default.nix
index cd7937f8a549..54cc09a4d18f 100644
--- a/pkgs/applications/graphics/autotrace/default.nix
+++ b/pkgs/applications/graphics/autotrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, callPackage, libpng12, imagemagick
+{ lib, stdenv, fetchurl, callPackage, libpng12, imagemagick
 , autoreconfHook, glib, pstoedit, pkgconfig, gettext, gd, darwin
 , runtimeShell }:
 
@@ -61,7 +61,7 @@ stdenv.mkDerivation rec {
     export PATH="$PATH:$PWD/wrappers"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://autotrace.sourceforge.net/";
     description = "Utility for converting bitmap into vector graphics";
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/avocode/default.nix b/pkgs/applications/graphics/avocode/default.nix
index 6d4fa501710d..65fc56f81b1c 100644
--- a/pkgs/applications/graphics/avocode/default.nix
+++ b/pkgs/applications/graphics/avocode/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, makeDesktopItem, fetchurl, unzip
+{ lib, stdenv, makeDesktopItem, fetchurl, unzip
 , gdk-pixbuf, glib, gtk3, atk, at-spi2-atk, pango, cairo, freetype, fontconfig, dbus, nss, nspr, alsaLib, cups, expat, udev, gnome3
 , xorg, mozjpeg, makeWrapper, wrapGAppsHook, libuuid, at-spi2-core
 }:
@@ -92,7 +92,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://avocode.com/";
     description = "The bridge between designers and developers";
     license = licenses.unfree;
diff --git a/pkgs/applications/graphics/azpainter/default.nix b/pkgs/applications/graphics/azpainter/default.nix
index c2e7ce6f35d3..74dc55fc5e13 100644
--- a/pkgs/applications/graphics/azpainter/default.nix
+++ b/pkgs/applications/graphics/azpainter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , libX11, libXext, libXi
 , freetype, fontconfig
 , libpng, libjpeg
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     zlib
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Full color painting software for illustration drawing";
     homepage = "https://osdn.net/projects/azpainter";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/batik/default.nix b/pkgs/applications/graphics/batik/default.nix
index 52a2589b409c..4b5974825543 100644
--- a/pkgs/applications/graphics/batik/default.nix
+++ b/pkgs/applications/graphics/batik/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl}:
+{lib, stdenv, fetchurl}:
 
 stdenv.mkDerivation rec {
   pname = "batik";
@@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
     sha256 = "16sq90nbs6psgm3xz30sbs6r5dnpd3qzsvr1xvnp4yipwjcmhmkw";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Java based toolkit for handling SVG";
     homepage = "https://xmlgraphics.apache.org/batik";
     license = licenses.asl20;
diff --git a/pkgs/applications/graphics/c3d/default.nix b/pkgs/applications/graphics/c3d/default.nix
index 425ede037593..4317cc78cda3 100644
--- a/pkgs/applications/graphics/c3d/default.nix
+++ b/pkgs/applications/graphics/c3d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, itk4, Cocoa }:
+{ lib, stdenv, fetchFromGitHub, cmake, itk4, Cocoa }:
 
 stdenv.mkDerivation rec {
   pname   = "c3d";
@@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
   buildInputs = [ itk4 ]
     ++ stdenv.lib.optional stdenv.isDarwin Cocoa;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/pyushkevich/c3d";
     description = "Medical imaging processing tool";
     maintainers = with maintainers; [ bcdarwin ];
diff --git a/pkgs/applications/graphics/darktable/default.nix b/pkgs/applications/graphics/darktable/default.nix
index 27d4a4ab0e2e..c93b94ee1836 100644
--- a/pkgs/applications/graphics/darktable/default.nix
+++ b/pkgs/applications/graphics/darktable/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libsoup, graphicsmagick, json-glib, wrapGAppsHook
+{ lib, stdenv, fetchurl, libsoup, graphicsmagick, json-glib, wrapGAppsHook
 , cairo, cmake, ninja, curl, perl, llvm, desktop-file-utils, exiv2, glib
 , ilmbase, gtk3, intltool, lcms2, lensfun, libX11, libexif, libgphoto2, libjpeg
 , libpng, librsvg, libtiff, openexr, osm-gps-map, pkgconfig, sqlite, libxslt
@@ -52,7 +52,7 @@ stdenv.mkDerivation rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Virtual lighttable and darkroom for photographers";
     homepage = "https://www.darktable.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/deskew/default.nix b/pkgs/applications/graphics/deskew/default.nix
index 6af6d93477a5..66309ebf7acf 100644
--- a/pkgs/applications/graphics/deskew/default.nix
+++ b/pkgs/applications/graphics/deskew/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, libtiff, fpc }:
+{ lib, stdenv, fetchFromGitHub, libtiff, fpc }:
 
 stdenv.mkDerivation rec {
 
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     install -Dt $out/bin Bin/*
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line tool for deskewing scanned text documents";
     homepage = "https://bitbucket.org/galfar/app-deskew/overview";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/dia/default.nix b/pkgs/applications/graphics/dia/default.nix
index 6ec54201fbfa..da6047a02566 100644
--- a/pkgs/applications/graphics/dia/default.nix
+++ b/pkgs/applications/graphics/dia/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, autoconf, automake, libtool, gtk2, pkgconfig, perlPackages,
+{ lib, stdenv, fetchgit, autoconf, automake, libtool, gtk2, pkgconfig, perlPackages,
 libxml2, gettext, python, libxml2Python, docbook5, docbook_xsl,
 libxslt, intltool, libart_lgpl, withGNOME ? false, libgnomeui,
 gtk-mac-integration-gtk2 }:
@@ -29,7 +29,7 @@ stdenv.mkDerivation {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Gnome Diagram drawing software";
     homepage = "http://live.gnome.org/Dia";
     maintainers = with maintainers; [ raskin ];
diff --git a/pkgs/applications/graphics/djview/default.nix b/pkgs/applications/graphics/djview/default.nix
index 4d09f2ad5fe0..a7fc17ce29b1 100644
--- a/pkgs/applications/graphics/djview/default.nix
+++ b/pkgs/applications/graphics/djview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchurl
 , pkgconfig
@@ -43,7 +43,7 @@ mkDerivation rec {
     mozillaPlugin = "/lib/mozilla/plugins";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A portable DjVu viewer (Qt5) and browser (nsdejavu) plugin";
     homepage = "http://djvu.sourceforge.net/djview4.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/drawio/default.nix b/pkgs/applications/graphics/drawio/default.nix
index 0bb4364d6fa9..31dff2f9c2d6 100644
--- a/pkgs/applications/graphics/drawio/default.nix
+++ b/pkgs/applications/graphics/drawio/default.nix
@@ -84,7 +84,7 @@ stdenv.mkDerivation rec {
       --replace /opt/draw.io/drawio $out/bin/drawio
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A desktop application for creating diagrams";
     homepage = "https://about.draw.io/";
     license = licenses.asl20;
diff --git a/pkgs/applications/graphics/epeg/default.nix b/pkgs/applications/graphics/epeg/default.nix
index bdbdf04bcd50..75f1fb9acd15 100644
--- a/pkgs/applications/graphics/epeg/default.nix
+++ b/pkgs/applications/graphics/epeg/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig, libtool, autoconf, automake
+{ lib, stdenv, fetchFromGitHub, pkgconfig, libtool, autoconf, automake
 , libjpeg, libexif
 }:
 
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
     ./autogen.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/mattes/epeg";
     description = "Insanely fast JPEG/ JPG thumbnail scaling";
     platforms = platforms.linux ++ platforms.darwin;
diff --git a/pkgs/applications/graphics/exrtools/default.nix b/pkgs/applications/graphics/exrtools/default.nix
index 39c23eb4fe8c..c50b6d0c2ad8 100644
--- a/pkgs/applications/graphics/exrtools/default.nix
+++ b/pkgs/applications/graphics/exrtools/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, openexr, libpng12, libjpeg }:
+{ lib, stdenv, fetchurl, pkgconfig, openexr, libpng12, libjpeg }:
 
 stdenv.mkDerivation rec {
   pname = "exrtools";
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ pkgconfig ];
   buildInputs = [ stdenv openexr libpng12 libjpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Collection of utilities for manipulating OpenEXR images";
     homepage = "http://scanline.ca/exrtools";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/f3d/default.nix b/pkgs/applications/graphics/f3d/default.nix
index c81ba1240173..e90d0e13f225 100644
--- a/pkgs/applications/graphics/f3d/default.nix
+++ b/pkgs/applications/graphics/f3d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitLab, cmake, vtk_9, libX11, libGL, Cocoa, OpenGL }:
+{ lib, stdenv, fetchFromGitLab, cmake, vtk_9, libX11, libGL, Cocoa, OpenGL }:
 
 stdenv.mkDerivation rec {
   pname = "f3d";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
     ++ stdenv.lib.optionals stdenv.isLinux [ libGL libX11 ]
     ++ stdenv.lib.optionals stdenv.isDarwin [ Cocoa OpenGL ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and minimalist 3D viewer using VTK";
     homepage = "https://kitware.github.io/F3D";
     license = licenses.bsd3;
diff --git a/pkgs/applications/graphics/fbida/default.nix b/pkgs/applications/graphics/fbida/default.nix
index 7f0167f98342..4754cc1a0241 100644
--- a/pkgs/applications/graphics/fbida/default.nix
+++ b/pkgs/applications/graphics/fbida/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjpeg, libexif, libungif, libtiff, libpng, libwebp, libdrm
+{ lib, stdenv, fetchurl, libjpeg, libexif, libungif, libtiff, libpng, libwebp, libdrm
 , pkgconfig, freetype, fontconfig, which, imagemagick, curl, sane-backends, libXpm
 , epoxy, poppler, mesa, lirc }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
     sed -e 's@$(HAVE_LINUX_FB_H)@yes@' -i GNUmakefile
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Image viewing and manipulation programs including fbi, fbgs, ida, exiftran and thumbnail.cgi";
     homepage = "https://www.kraxel.org/blog/linux/fbida/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/fig2dev/default.nix b/pkgs/applications/graphics/fig2dev/default.nix
index cd7db3d29c50..c22bbbb48278 100644
--- a/pkgs/applications/graphics/fig2dev/default.nix
+++ b/pkgs/applications/graphics/fig2dev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, ghostscript, libpng } :
+{ lib, stdenv, fetchurl, ghostscript, libpng } :
 
 let
   version = "3.2.7b";
@@ -16,7 +16,7 @@ in stdenv.mkDerivation {
 
   GSEXE="${ghostscript}/bin/gs";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Tool to convert Xfig files to other formats";
     homepage = "http://mcj.sourceforge.net/";
     license = licenses.xfig;
diff --git a/pkgs/applications/graphics/fluxus/default.nix b/pkgs/applications/graphics/fluxus/default.nix
index f560ad45c574..05260dc9812a 100644
--- a/pkgs/applications/graphics/fluxus/default.nix
+++ b/pkgs/applications/graphics/fluxus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , alsaLib
 , bzip2
@@ -87,7 +87,7 @@ stdenv.mkDerivation rec {
     cp -r build$out/* $out/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Livecoding environment for 3D graphics, sound, and games";
     license = licenses.gpl2;
     homepage = "http://www.pawfal.org/fluxus/";
diff --git a/pkgs/applications/graphics/fondo/default.nix b/pkgs/applications/graphics/fondo/default.nix
index 73cfdccea816..ee75d6e1ae05 100644
--- a/pkgs/applications/graphics/fondo/default.nix
+++ b/pkgs/applications/graphics/fondo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , pantheon
@@ -64,7 +64,7 @@ stdenv.mkDerivation rec {
   };
 
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Find the most beautiful wallpapers for your desktop";
     homepage = "https://github.com/calo001/fondo";
     license = licenses.agpl3Plus;
diff --git a/pkgs/applications/graphics/freecad/default.nix b/pkgs/applications/graphics/freecad/default.nix
index 1c272cf44e24..cb37a81d9e1a 100644
--- a/pkgs/applications/graphics/freecad/default.nix
+++ b/pkgs/applications/graphics/freecad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchFromGitHub, fetchpatch, cmake, ninja, coin3d,
+{ lib, stdenv, mkDerivation, fetchFromGitHub, fetchpatch, cmake, ninja, coin3d,
 xercesc, ode, eigen, qtbase, qttools, qtwebengine, qtxmlpatterns, wrapQtAppsHook,
 opencascade-occt, gts, hdf5, vtk, medfile, zlib, python3Packages, swig,
 gfortran, libXmu, soqt, libf2c, libGLU, makeWrapper, pkgconfig, mpi ? null }:
@@ -67,7 +67,7 @@ in mkDerivation rec {
     mv $out/share/doc $out
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "General purpose Open Source 3D CAD/MCAD/CAx/CAE/PLM modeler";
     homepage = "https://www.freecadweb.org/";
     license = licenses.lgpl2Plus;
diff --git a/pkgs/applications/graphics/fstl/default.nix b/pkgs/applications/graphics/fstl/default.nix
index 75c43f06d2c3..e7eb2c4f92ac 100644
--- a/pkgs/applications/graphics/fstl/default.nix
+++ b/pkgs/applications/graphics/fstl/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, mkDerivation, qtbase, mesa_glu }:
+{ lib, stdenv, fetchFromGitHub, mkDerivation, qtbase, mesa_glu }:
 
 mkDerivation rec {
   pname = "fstl";
@@ -26,7 +26,7 @@ mkDerivation rec {
     sha256 = "028hzdv11hgvcpc36q5scf4nw1256qswh37xhfn5a0iv7wycmnif";
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "The fastest STL file viewer";
     homepage = "https://github.com/mkeeter/fstl";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/gcolor3/default.nix b/pkgs/applications/graphics/gcolor3/default.nix
index 2962825e49b1..2771559416bf 100644
--- a/pkgs/applications/graphics/gcolor3/default.nix
+++ b/pkgs/applications/graphics/gcolor3/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , meson
 , ninja
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
     patchShebangs meson_install.sh
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple color chooser written in GTK3";
     homepage = "https://gitlab.gnome.org/World/gcolor3";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/geeqie/default.nix b/pkgs/applications/graphics/geeqie/default.nix
index 629abb3321d5..7167700c244c 100644
--- a/pkgs/applications/graphics/geeqie/default.nix
+++ b/pkgs/applications/graphics/geeqie/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, autoconf, automake, gettext, intltool
+{ lib, stdenv, fetchurl, pkgconfig, autoconf, automake, gettext, intltool
 , gtk3, lcms2, exiv2, libchamplain, clutter-gtk, ffmpegthumbnailer, fbida
 , wrapGAppsHook, fetchpatch
 }:
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Lightweight GTK based image viewer";
 
     longDescription =
diff --git a/pkgs/applications/graphics/gimp/plugins/default.nix b/pkgs/applications/graphics/gimp/plugins/default.nix
index 84f5abfce063..7ea76c9a8245 100644
--- a/pkgs/applications/graphics/gimp/plugins/default.nix
+++ b/pkgs/applications/graphics/gimp/plugins/default.nix
@@ -69,7 +69,7 @@ in
     };
     NIX_LDFLAGS = "-lm";
     hardeningDisable = [ "format" ];
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "The GIMP Animation Package";
       homepage = "https://www.gimp.org";
       # The main code is given in GPLv3, but it has ffmpeg in it, and I think ffmpeg license
@@ -93,7 +93,7 @@ in
 
     installPhase = "installPlugins fourier";
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "GIMP plug-in to do the fourier transform";
       homepage = "https://people.via.ecp.fr/~remi/soft/gimp/gimp_plugin_en.php3#fourier";
       license = with licenses; [ gpl3Plus ];
diff --git a/pkgs/applications/graphics/glabels/default.nix b/pkgs/applications/graphics/glabels/default.nix
index be487fcb8a6b..c6b7b60c98e8 100644
--- a/pkgs/applications/graphics/glabels/default.nix
+++ b/pkgs/applications/graphics/glabels/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, barcode, gnome3, autoreconfHook
+{ lib, stdenv, fetchurl, barcode, gnome3, autoreconfHook
 , gtk3, gtk-doc, libxml2, librsvg , libtool, libe-book, gsettings-desktop-schemas
 , intltool, itstool, makeWrapper, pkgconfig, yelp-tools
 }:
@@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Create labels and business cards";
     homepage = "https://glabels.org/";
     license = with licenses; [ gpl3Plus lgpl3Plus ];
diff --git a/pkgs/applications/graphics/gnome-photos/default.nix b/pkgs/applications/graphics/gnome-photos/default.nix
index 0d4b06c8c6d5..425762fdaa96 100644
--- a/pkgs/applications/graphics/gnome-photos/default.nix
+++ b/pkgs/applications/graphics/gnome-photos/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , at-spi2-core
@@ -131,7 +131,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Access, organize and share your photos";
     homepage = "https://wiki.gnome.org/Apps/Photos";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/gnuclad/default.nix b/pkgs/applications/graphics/gnuclad/default.nix
index c36d576cc8e2..e4a82703febb 100644
--- a/pkgs/applications/graphics/gnuclad/default.nix
+++ b/pkgs/applications/graphics/gnuclad/default.nix
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   nativeBuildInputs = [ pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://launchpad.net/gnuclad";
     description = "gnuclad tries to help the environment by creating trees.  Its primary use will be generating cladogram trees for the GNU/Linux distro timeline project";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/goxel/default.nix b/pkgs/applications/graphics/goxel/default.nix
index 771109fb55d2..ec51e077c568 100644
--- a/pkgs/applications/graphics/goxel/default.nix
+++ b/pkgs/applications/graphics/goxel/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, scons, pkgconfig, wrapGAppsHook
+{ lib, stdenv, fetchFromGitHub, scons, pkgconfig, wrapGAppsHook
 , glfw3, gtk3, libpng12 }:
 
 stdenv.mkDerivation rec {
@@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
     install -D ./goxel $out/bin/goxel
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open Source 3D voxel editor";
     homepage = "https://guillaumechereau.github.io/goxel/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/gpicview/default.nix b/pkgs/applications/graphics/gpicview/default.nix
index 9e3ab37c3223..e686aa4f3591 100644
--- a/pkgs/applications/graphics/gpicview/default.nix
+++ b/pkgs/applications/graphics/gpicview/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, intltool, pkgconfig, gtk2, fetchpatch }:
+{ lib, stdenv, fetchurl, intltool, pkgconfig, gtk2, fetchpatch }:
 
 stdenv.mkDerivation {
   name = "gpicview-0.2.4";
@@ -15,7 +15,7 @@ stdenv.mkDerivation {
     })
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A simple and fast image viewer for X";
     homepage    = "http://lxde.sourceforge.net/gpicview/";
     repositories.git = "git://lxde.git.sourceforge.net/gitroot/lxde/gpicview";
diff --git a/pkgs/applications/graphics/gqview/default.nix b/pkgs/applications/graphics/gqview/default.nix
index 965ac5db6821..6ea67e332129 100644
--- a/pkgs/applications/graphics/gqview/default.nix
+++ b/pkgs/applications/graphics/gqview/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchurl, pkgconfig, gtk2, libpng}:
+{lib, stdenv, fetchurl, pkgconfig, gtk2, libpng}:
 
 assert pkgconfig != null && gtk2 != null && libpng != null;
 # Note that we cannot just copy gtk's png attribute, since gtk might
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
 
   NIX_LDFLAGS = "-lm";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fast image viewer";
     homepage = "http://gqview.sourceforge.net";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/gthumb/default.nix b/pkgs/applications/graphics/gthumb/default.nix
index 7dbe03d9f281..c97e28c9f9af 100644
--- a/pkgs/applications/graphics/gthumb/default.nix
+++ b/pkgs/applications/graphics/gthumb/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , fetchpatch
 , gnome3
@@ -101,7 +101,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/Gthumb";
     description = "Image browser and viewer for GNOME";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/hugin/default.nix b/pkgs/applications/graphics/hugin/default.nix
index 1a8a552aa4f4..17d1dc326766 100644
--- a/pkgs/applications/graphics/hugin/default.nix
+++ b/pkgs/applications/graphics/hugin/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, cmake, fetchurl, gnumake, makeWrapper, pkgconfig, fetchpatch
+{ lib, stdenv, cmake, fetchurl, gnumake, makeWrapper, pkgconfig, fetchpatch
 , autopanosiftc, boost, cairo, enblend-enfuse, exiv2, fftw, flann, gettext
 , glew, ilmbase, lcms2, lensfun, libjpeg, libpng, libtiff, libX11, libXi
 , libXmu, libGLU, libGL, openexr, panotools, perlPackages, sqlite, vigra, wxGTK, zlib
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://hugin.sourceforge.net/";
     description = "Toolkit for stitching photographs and assembling panoramas, together with an easy to use graphical front end";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/hydrus/default.nix b/pkgs/applications/graphics/hydrus/default.nix
index 8e9998dde393..69fdb9e2e114 100644
--- a/pkgs/applications/graphics/hydrus/default.nix
+++ b/pkgs/applications/graphics/hydrus/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , lzma
 , qt5
@@ -103,7 +103,7 @@ pythonPackages.buildPythonPackage {
     makeWrapperArgs+=("''${qtWrapperArgs[@]}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Danbooru-like image tagging and searching system for the desktop";
     license = licenses.wtfpl;
     homepage = "https://hydrusnetwork.github.io/hydrus/";
diff --git a/pkgs/applications/graphics/ideogram/default.nix b/pkgs/applications/graphics/ideogram/default.nix
index 9ae7ae2cb8ce..fbee1d5b0e83 100644
--- a/pkgs/applications/graphics/ideogram/default.nix
+++ b/pkgs/applications/graphics/ideogram/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , nix-update-script
 , fetchpatch
@@ -57,7 +57,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Insert emoji anywhere, even in non-native apps - designed for elementary OS";
     homepage = "https://github.com/cassidyjames/ideogram";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/imagej/default.nix b/pkgs/applications/graphics/imagej/default.nix
index d47369f5094a..7e3238e94bbc 100644
--- a/pkgs/applications/graphics/imagej/default.nix
+++ b/pkgs/applications/graphics/imagej/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, jre, unzip, makeWrapper }:
+{ lib, stdenv, fetchurl, jre, unzip, makeWrapper }:
 
 # Note:
 # - User config dir is hard coded by upstream to $HOME/.imagej on linux systems
@@ -31,7 +31,7 @@ let
       makeWrapper ${jre}/bin/java $out/bin/imagej \
         --add-flags "-jar $out/share/java/ij.jar -ijpath $out/share"
     '';
-    meta = with stdenv.lib; {
+    meta = with lib; {
       homepage = "https://imagej.nih.gov/ij/";
       description = "Image processing and analysis in Java";
       longDescription = ''
diff --git a/pkgs/applications/graphics/imgbrd-grabber/default.nix b/pkgs/applications/graphics/imgbrd-grabber/default.nix
index 22a35b3a4cc3..c0115d95ac80 100644
--- a/pkgs/applications/graphics/imgbrd-grabber/default.nix
+++ b/pkgs/applications/graphics/imgbrd-grabber/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , cmake
 , fetchFromGitHub
 , wrapQtAppsHook
@@ -85,7 +85,7 @@ stdenv.mkDerivation rec {
 
   sourceRoot = "source/src";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Very customizable imageboard/booru downloader with powerful filenaming features";
     license = licenses.asl20;
     homepage = "https://bionus.github.io/imgbrd-grabber/";
diff --git a/pkgs/applications/graphics/imgcat/default.nix b/pkgs/applications/graphics/imgcat/default.nix
index 5943632930c5..cb2301d6339e 100644
--- a/pkgs/applications/graphics/imgcat/default.nix
+++ b/pkgs/applications/graphics/imgcat/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, autoconf, automake, libtool, ncurses }:
+{ lib, stdenv, fetchFromGitHub, autoconf, automake, libtool, ncurses }:
 
 stdenv.mkDerivation rec {
   pname = "imgcat";
@@ -23,7 +23,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-Wno-error";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "It's like cat, but for images";
     homepage = "https://github.com/eddieantonio/imgcat";
     license = licenses.isc;
diff --git a/pkgs/applications/graphics/imlibsetroot/default.nix b/pkgs/applications/graphics/imlibsetroot/default.nix
index 06549468efe9..d3640a656f13 100644
--- a/pkgs/applications/graphics/imlibsetroot/default.nix
+++ b/pkgs/applications/graphics/imlibsetroot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libX11, libXinerama, imlib2 }:
+{ lib, stdenv, fetchurl, libX11, libXinerama, imlib2 }:
 
 stdenv.mkDerivation {
   pname = "imlibsetroot";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -m 755 imlibsetroot $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Xinerama Aware Background Changer";
     homepage = "http://robotmonkeys.net/2010/03/30/imlibsetroot/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/imv/default.nix b/pkgs/applications/graphics/imv/default.nix
index 71e156881c40..067abb785b47 100644
--- a/pkgs/applications/graphics/imv/default.nix
+++ b/pkgs/applications/graphics/imv/default.nix
@@ -101,7 +101,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line image viewer for tiling window managers";
     homepage = "https://github.com/eXeC64/imv";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/inkscape/default.nix b/pkgs/applications/graphics/inkscape/default.nix
index 810b19ba90a6..be89d32e722a 100644
--- a/pkgs/applications/graphics/inkscape/default.nix
+++ b/pkgs/applications/graphics/inkscape/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , boehmgc
 , boost
 , cairo
@@ -135,7 +135,7 @@ stdenv.mkDerivation rec {
     install_name_tool -change $out/lib/libinkscape_base.dylib $out/lib/inkscape/libinkscape_base.dylib $out/bin/inkview
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Vector graphics editor";
     homepage = "https://www.inkscape.org";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/inkscape/extensions.nix b/pkgs/applications/graphics/inkscape/extensions.nix
index 013d3bec3527..affd934e9368 100644
--- a/pkgs/applications/graphics/inkscape/extensions.nix
+++ b/pkgs/applications/graphics/inkscape/extensions.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , runCommand
 , inkcut
@@ -28,7 +28,7 @@
       runHook postInstall
     '';
 
-    meta = with stdenv.lib; {
+    meta = with lib; {
       description = "This is an extension for creating hex grids in Inkscape. It can also be used to make brick patterns of staggered rectangles";
       homepage = "https://github.com/lifelike/hexmapextension";
       license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/jpeg-archive/default.nix b/pkgs/applications/graphics/jpeg-archive/default.nix
index 8beaf43c089c..cac930dae143 100644
--- a/pkgs/applications/graphics/jpeg-archive/default.nix
+++ b/pkgs/applications/graphics/jpeg-archive/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, mozjpeg, makeWrapper, coreutils, parallel, findutils }:
+{ lib, stdenv, fetchFromGitHub, mozjpeg, makeWrapper, coreutils, parallel, findutils }:
 
 stdenv.mkDerivation {
   pname = "jpeg-archive";
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
       --set PATH "$out/bin:${coreutils}/bin:${parallel}/bin:${findutils}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Utilities for archiving photos for saving to long term storage or serving over the web";
     homepage    = "https://github.com/danielgtaylor/jpeg-archive";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/jpeginfo/default.nix b/pkgs/applications/graphics/jpeginfo/default.nix
index e15aedd77e1c..1660d89eacf9 100644
--- a/pkgs/applications/graphics/jpeginfo/default.nix
+++ b/pkgs/applications/graphics/jpeginfo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjpeg }:
+{ lib, stdenv, fetchurl, libjpeg }:
 
 stdenv.mkDerivation rec {
   pname = "jpeginfo";
@@ -11,7 +11,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libjpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Prints information and tests integrity of JPEG/JFIF files";
     homepage = "https://www.kokkonen.net/tjko/projects.html";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/jpegoptim/default.nix b/pkgs/applications/graphics/jpegoptim/default.nix
index 265ce82b8ac3..6095d81c528d 100644
--- a/pkgs/applications/graphics/jpegoptim/default.nix
+++ b/pkgs/applications/graphics/jpegoptim/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, libjpeg }:
+{ lib, stdenv, fetchurl, libjpeg }:
 
 stdenv.mkDerivation rec {
   version = "1.4.6";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   buildInputs = [ libjpeg ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optimize JPEG files";
     homepage = "https://www.kokkonen.net/tjko/projects.html";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/jpegrescan/default.nix b/pkgs/applications/graphics/jpegrescan/default.nix
index 5fe35edabdf6..1a7320bf6930 100644
--- a/pkgs/applications/graphics/jpegrescan/default.nix
+++ b/pkgs/applications/graphics/jpegrescan/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, libjpeg_turbo, perl, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, libjpeg_turbo, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "jpegrescan";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     perl libjpeg_turbo makeWrapper
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "losslessly shrink any JPEG file";
     homepage = "https://github.com/kud/jpegrescan";
     license = licenses.publicDomain;
diff --git a/pkgs/applications/graphics/k3d/default.nix b/pkgs/applications/graphics/k3d/default.nix
index c74f35e4334a..c333ecaa99fd 100644
--- a/pkgs/applications/graphics/k3d/default.nix
+++ b/pkgs/applications/graphics/k3d/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch, ftgl, glew, asciidoc
+{ lib, stdenv, fetchFromGitHub, fetchpatch, ftgl, glew, asciidoc
 , cmake, ninja, libGLU, libGL, zlib, python, expat, libxml2, libsigcxx, libuuid, freetype
 , libpng, boost, doxygen, cairomm, pkgconfig, libjpeg, libtiff
 , gettext, intltool, perl, gtkmm2, glibmm, gtkglext, libXmu }:
@@ -41,7 +41,7 @@ stdenv.mkDerivation rec {
 
   NIX_CFLAGS_COMPILE = "-Wno-deprecated-declarations";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 3D editor with support for procedural editing";
     homepage = "http://www.k-3d.org/";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/kgraphviewer/default.nix b/pkgs/applications/graphics/kgraphviewer/default.nix
index eaef8c13b7c8..4f3e08bf7b0f 100644
--- a/pkgs/applications/graphics/kgraphviewer/default.nix
+++ b/pkgs/applications/graphics/kgraphviewer/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, fetchurl, cmake, extra-cmake-modules, pkgconfig, wrapGAppsHook
+{ lib, stdenv, mkDerivation, fetchurl, cmake, extra-cmake-modules, pkgconfig, wrapGAppsHook
 , kconfig, kinit, kdoctools, kio, kparts, kwidgetsaddons
 , qtbase, qtsvg
 , boost, graphviz
@@ -27,7 +27,7 @@ mkDerivation rec {
     kconfig kinit kio kparts kwidgetsaddons
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A Graphviz dot graph viewer for KDE";
     license     = licenses.gpl2;
     maintainers = with maintainers; [ lethalman ];
diff --git a/pkgs/applications/graphics/kodelife/default.nix b/pkgs/applications/graphics/kodelife/default.nix
index e5aac9b8823d..80abca80f87f 100644
--- a/pkgs/applications/graphics/kodelife/default.nix
+++ b/pkgs/applications/graphics/kodelife/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchzip
 , alsaLib
 , glib
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
       $out/bin/KodeLife
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://hexler.net/products/kodelife";
     description = "Real-time GPU shader editor";
     license = licenses.unfree;
diff --git a/pkgs/applications/graphics/ktikz/default.nix b/pkgs/applications/graphics/ktikz/default.nix
index d0d9f100878f..1872d976f8e3 100644
--- a/pkgs/applications/graphics/ktikz/default.nix
+++ b/pkgs/applications/graphics/ktikz/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchpatch
+{ lib, stdenv, fetchFromGitHub, fetchpatch
 , pkgconfig, wrapQtAppsHook
 , poppler, gnuplot
 , qmake, qtbase, qttools
@@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
   version = "0.12";
   pname = "qtikz";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Editor for the TikZ language";
     homepage = "https://github.com/fhackenberger/ktikz";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/lazpaint/default.nix b/pkgs/applications/graphics/lazpaint/default.nix
index e53c36b59cd9..2756414d30de 100644
--- a/pkgs/applications/graphics/lazpaint/default.nix
+++ b/pkgs/applications/graphics/lazpaint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, lazarus, fpc, pango, cairo, glib
+{ lib, stdenv, fetchFromGitHub, lazarus, fpc, pango, cairo, glib
 , atk, gtk2, libX11, gdk-pixbuf, busybox, python3, makeWrapper }:
 
 with stdenv;
@@ -58,7 +58,7 @@ in stdenv.mkDerivation rec {
       --prefix PATH : ${stdenv.lib.makeBinPath [ python3 ]}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Image editor like PaintBrush or Paint.Net";
     homepage = "https://sourceforge.net/projects/lazpaint/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/leocad/default.nix b/pkgs/applications/graphics/leocad/default.nix
index 5e950eeac04b..39a287900a9a 100644
--- a/pkgs/applications/graphics/leocad/default.nix
+++ b/pkgs/applications/graphics/leocad/default.nix
@@ -3,7 +3,7 @@ To use aditional parts libraries
 set the variable LEOCAD_LIB=/path/to/libs/ or use option -l /path/to/libs/
 */
 
-{ stdenv, fetchFromGitHub, qt4, qmake4Hook, zlib }:
+{ lib, stdenv, fetchFromGitHub, qt4, qmake4Hook, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "leocad";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     export qmakeFlags="$qmakeFlags INSTALL_PREFIX=$out"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "CAD program for creating virtual LEGO models";
     homepage = "https://www.leocad.org/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/luminance-hdr/default.nix b/pkgs/applications/graphics/luminance-hdr/default.nix
index 811a907746d5..9b1dbe537956 100644
--- a/pkgs/applications/graphics/luminance-hdr/default.nix
+++ b/pkgs/applications/graphics/luminance-hdr/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivation, cmake, fetchFromGitHub, pkgconfig
+{ lib, stdenv, mkDerivation, cmake, fetchFromGitHub, pkgconfig
 , boost, exiv2, fftwFloat, gsl
 , ilmbase, lcms2, libraw, libtiff, openexr
 , qtbase, qtdeclarative, qttools, qtwebengine, eigen
@@ -24,7 +24,7 @@ mkDerivation rec {
 
   nativeBuildInputs = [ cmake pkgconfig ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://qtpfsgui.sourceforge.net/";
     description = "A complete open source solution for HDR photography";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/mcomix3/default.nix b/pkgs/applications/graphics/mcomix3/default.nix
index 24c80a6bd877..81077578eb27 100644
--- a/pkgs/applications/graphics/mcomix3/default.nix
+++ b/pkgs/applications/graphics/mcomix3/default.nix
@@ -87,7 +87,7 @@ python3.pkgs.buildPythonApplication rec {
     $out/bin/${pname} --help > /dev/null
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Comic book reader and image viewer; python3 fork of mcomix";
     longDescription = ''
       User-friendly, customizable image viewer, specifically designed to handle
diff --git a/pkgs/applications/graphics/meme/default.nix b/pkgs/applications/graphics/meme/default.nix
index 5425b8bef23c..c894de2c9330 100644
--- a/pkgs/applications/graphics/meme/default.nix
+++ b/pkgs/applications/graphics/meme/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , unstableGitUpdater
 , buildGoModule
 , fetchFromGitHub
@@ -19,7 +19,7 @@ buildGoModule {
 
   passthru.updateScript = unstableGitUpdater { };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A command line utility for creating image macro style memes";
     homepage = "https://github.com/nomad-software/meme";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/monado/default.nix b/pkgs/applications/graphics/monado/default.nix
index 7502ab69c320..395ae028423a 100644
--- a/pkgs/applications/graphics/monado/default.nix
+++ b/pkgs/applications/graphics/monado/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , fetchpatch
 , writeText
@@ -120,7 +120,7 @@ stdenv.mkDerivation rec {
     export XDG_CONFIG_DIRS=@out@/etc/xdg''${XDG_CONFIG_DIRS:+:''${XDG_CONFIG_DIRS}}
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Open source XR runtime";
     homepage = "https://monado.freedesktop.org/";
     license = licenses.boost;
diff --git a/pkgs/applications/graphics/mypaint/default.nix b/pkgs/applications/graphics/mypaint/default.nix
index 7267e8401600..3b030a1eb578 100644
--- a/pkgs/applications/graphics/mypaint/default.nix
+++ b/pkgs/applications/graphics/mypaint/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , gtk3
 , gettext
@@ -90,7 +90,7 @@ in buildPythonApplication rec {
     runHook postCheck
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A graphics application for digital painters";
     homepage = "http://mypaint.org/";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/nomacs/default.nix b/pkgs/applications/graphics/nomacs/default.nix
index d79a35665743..3c571fedb830 100644
--- a/pkgs/applications/graphics/nomacs/default.nix
+++ b/pkgs/applications/graphics/nomacs/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , mkDerivation
 , fetchFromGitHub
 , fetchpatch
@@ -50,7 +50,7 @@ mkDerivation rec {
                 "-DENABLE_TRANSLATIONS=ON"
                 "-DUSE_SYSTEM_QUAZIP=ON"];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nomacs.org";
     description = "Qt-based image viewer";
     maintainers = with stdenv.lib.maintainers; [ mindavi ];
diff --git a/pkgs/applications/graphics/nufraw/default.nix b/pkgs/applications/graphics/nufraw/default.nix
index 678bc12278df..e49093c568cb 100644
--- a/pkgs/applications/graphics/nufraw/default.nix
+++ b/pkgs/applications/graphics/nufraw/default.nix
@@ -54,7 +54,7 @@ stdenv.mkDerivation rec {
     substituteAll ${./nufraw.thumbnailer} $out/share/thumbnailers/${pname}.thumbnailer
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://nufraw.sourceforge.io/";
     description = "Utility to read and manipulate raw images from digital cameras";
     longDescription =
diff --git a/pkgs/applications/graphics/ocrad/default.nix b/pkgs/applications/graphics/ocrad/default.nix
index 80f592681110..476d56fb3fe3 100644
--- a/pkgs/applications/graphics/ocrad/default.nix
+++ b/pkgs/applications/graphics/ocrad/default.nix
@@ -1,4 +1,4 @@
-{ fetchurl, stdenv, lzip, texinfo }:
+{ fetchurl, lib, stdenv, lzip, texinfo }:
 
 stdenv.mkDerivation rec {
   pname = "ocrad";
@@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
 
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Optical character recognition (OCR) program & library";
     longDescription =
       '' GNU Ocrad is an OCR (Optical Character Recognition) program based on
diff --git a/pkgs/applications/graphics/ocrfeeder/default.nix b/pkgs/applications/graphics/ocrfeeder/default.nix
index 28fe58183fae..95ff90a8eeff 100644
--- a/pkgs/applications/graphics/ocrfeeder/default.nix
+++ b/pkgs/applications/graphics/ocrfeeder/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , pkg-config
 , gtk3
@@ -63,7 +63,7 @@ stdenv.mkDerivation rec {
     gappsWrapperArgs+=(--prefix PATH : "${enginesPath}")
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://wiki.gnome.org/Apps/OCRFeeder";
     description = "Complete Optical Character Recognition and Document Analysis and Recognition program";
     maintainers = with maintainers; [ doronbehar ];
diff --git a/pkgs/applications/graphics/odafileconverter/default.nix b/pkgs/applications/graphics/odafileconverter/default.nix
index 0d1d64f3dd05..a74043730bf5 100644
--- a/pkgs/applications/graphics/odafileconverter/default.nix
+++ b/pkgs/applications/graphics/odafileconverter/default.nix
@@ -43,7 +43,7 @@ in mkDerivation {
     done
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "For converting between different versions of .dwg and .dxf";
     homepage = "https://www.opendesign.com/guestfiles/oda_file_converter";
     license = licenses.unfree;
diff --git a/pkgs/applications/graphics/openimageio/2.x.nix b/pkgs/applications/graphics/openimageio/2.x.nix
index 89d49a151457..b200b9be8cd9 100644
--- a/pkgs/applications/graphics/openimageio/2.x.nix
+++ b/pkgs/applications/graphics/openimageio/2.x.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , fetchpatch
 , boost
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
     "-DCMAKE_INSTALL_LIBDIR=lib" # needs relative path for pkgconfig
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.openimageio.org";
     description = "A library and tools for reading and writing images";
     license = licenses.bsd3;
diff --git a/pkgs/applications/graphics/openimageio/default.nix b/pkgs/applications/graphics/openimageio/default.nix
index 1f2861e7109c..8bd82c783932 100644
--- a/pkgs/applications/graphics/openimageio/default.nix
+++ b/pkgs/applications/graphics/openimageio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, cmake, ilmbase, libjpeg, libpng, libtiff
+{ lib, stdenv, fetchFromGitHub, boost, cmake, ilmbase, libjpeg, libpng, libtiff
 , opencolorio, openexr, unzip
 }:
 
@@ -33,7 +33,7 @@ stdenv.mkDerivation rec {
     "dist_dir="
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.openimageio.org";
     description = "A library and tools for reading and writing images";
     license = licenses.bsd3;
diff --git a/pkgs/applications/graphics/paraview/default.nix b/pkgs/applications/graphics/paraview/default.nix
index d0c8d1c9ee94..6e4738dd07c1 100644
--- a/pkgs/applications/graphics/paraview/default.nix
+++ b/pkgs/applications/graphics/paraview/default.nix
@@ -1,6 +1,6 @@
 { boost, cmake, fetchFromGitHub, ffmpeg, qtbase, qtx11extras,
   qttools, qtxmlpatterns, qtsvg, gdal, gfortran, libXt, makeWrapper,
-  mkDerivation, ninja, openmpi, python3, stdenv, tbb, libGLU, libGL }:
+  mkDerivation, ninja, openmpi, python3, lib, stdenv, tbb, libGLU, libGL }:
 
 mkDerivation rec {
   pname = "paraview";
@@ -81,7 +81,7 @@ mkDerivation rec {
     (python3.withPackages (ps: with ps; [ numpy matplotlib mpi4py ]))
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://www.paraview.org/";
     description = "3D Data analysis and visualization application";
     license = licenses.free;
diff --git a/pkgs/applications/graphics/pbrt/default.nix b/pkgs/applications/graphics/pbrt/default.nix
index e699b453bcf5..9fdf92a4ae80 100644
--- a/pkgs/applications/graphics/pbrt/default.nix
+++ b/pkgs/applications/graphics/pbrt/default.nix
@@ -1,4 +1,4 @@
-{stdenv, fetchFromGitHub, flex, bison, cmake, git, zlib}:
+{lib, stdenv, fetchFromGitHub, flex, bison, cmake, git, zlib}:
 
 stdenv.mkDerivation {
   version = "2018-08-15";
@@ -20,7 +20,7 @@ stdenv.mkDerivation {
   nativeBuildInputs = [ flex bison cmake ];
   buildInputs = [ zlib ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://pbrt.org";
     description = "The renderer described in the third edition of the book 'Physically Based Rendering: From Theory To Implementation'";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/pdfcpu/default.nix b/pkgs/applications/graphics/pdfcpu/default.nix
index 3f91fae0beb7..3a06c8e31f7d 100644
--- a/pkgs/applications/graphics/pdfcpu/default.nix
+++ b/pkgs/applications/graphics/pdfcpu/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, buildGoModule, fetchFromGitHub }:
+{ lib, stdenv, buildGoModule, fetchFromGitHub }:
 
 buildGoModule rec {
   pname = "pdfcpu";
@@ -18,7 +18,7 @@ buildGoModule rec {
 
   subPackages = [ "cmd/pdfcpu" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A PDF processor written in Go";
     homepage = "https://pdfcpu.io";
     license = licenses.asl20;
diff --git a/pkgs/applications/graphics/pencil/default.nix b/pkgs/applications/graphics/pencil/default.nix
index 19e8121ac08d..be3b07bf4cc7 100644
--- a/pkgs/applications/graphics/pencil/default.nix
+++ b/pkgs/applications/graphics/pencil/default.nix
@@ -96,7 +96,7 @@ in stdenv.mkDerivation rec {
       --prefix LD_LIBRARY_PATH : $out/opt/pencil
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "GUI prototyping/mockup tool";
     homepage    = "https://pencil.evolus.vn/";
     license     = licenses.gpl2; # Commercial license is also available
diff --git a/pkgs/applications/graphics/photivo/default.nix b/pkgs/applications/graphics/photivo/default.nix
index 3c89f3ffac03..b44130c47ae1 100644
--- a/pkgs/applications/graphics/photivo/default.nix
+++ b/pkgs/applications/graphics/photivo/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchhg, fetchpatch, cmake, qt4, fftw, graphicsmagick_q16,
+{ lib, stdenv, fetchhg, fetchpatch, cmake, qt4, fftw, graphicsmagick_q16,
   lcms2, lensfun, pkgconfig, libjpeg, exiv2, liblqr1 }:
 
 stdenv.mkDerivation {
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
 
   buildInputs = [ qt4 fftw graphicsmagick_q16 lcms2 lensfun libjpeg exiv2 liblqr1 ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     platforms = platforms.linux;
     license = licenses.gpl3;
     broken = true; # exiv2 0.27.1 FTBFS
diff --git a/pkgs/applications/graphics/photoflare/default.nix b/pkgs/applications/graphics/photoflare/default.nix
index f619d79c0f55..ca2455dd048c 100644
--- a/pkgs/applications/graphics/photoflare/default.nix
+++ b/pkgs/applications/graphics/photoflare/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, graphicsmagick, fetchFromGitHub, qmake, qtbase, qttools
+{ mkDerivation, lib, stdenv, graphicsmagick, fetchFromGitHub, qmake, qtbase, qttools
 }:
 
 mkDerivation rec {
@@ -21,7 +21,7 @@ mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A cross-platform image editor with a powerful features and a very friendly graphical user interface";
     homepage = "https://photoflare.io";
     maintainers = [ maintainers.omgbebebe ];
diff --git a/pkgs/applications/graphics/photoflow/default.nix b/pkgs/applications/graphics/photoflow/default.nix
index cb8ef65b2e9e..436d6764c75f 100644
--- a/pkgs/applications/graphics/photoflow/default.nix
+++ b/pkgs/applications/graphics/photoflow/default.nix
@@ -22,7 +22,7 @@
 , pcre
 , pkgconfig
 , pugixml
-, stdenv
+, lib, stdenv
 , swig
 , vips
 }:
@@ -78,7 +78,7 @@ stdenv.mkDerivation rec {
     "-DBUNDLED_GEXIV2=OFF"
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A fully non-destructive photo retouching program providing a complete RAW image editing workflow";
     homepage = "https://aferrero2707.github.io/PhotoFlow/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/phototonic/default.nix b/pkgs/applications/graphics/phototonic/default.nix
index 7020bf6c83e6..21960358a7bd 100644
--- a/pkgs/applications/graphics/phototonic/default.nix
+++ b/pkgs/applications/graphics/phototonic/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, qtbase, qmake, exiv2 }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, qtbase, qmake, exiv2 }:
 
 mkDerivation rec {
   pname = "phototonic";
@@ -18,7 +18,7 @@ mkDerivation rec {
     sed -i 's;/usr;$$PREFIX/;g' phototonic.pro
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An image viewer and organizer";
     homepage = "https://sourceforge.net/projects/phototonic/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/pick-colour-picker/default.nix b/pkgs/applications/graphics/pick-colour-picker/default.nix
index e34d5a87a478..d4788b3c1e76 100644
--- a/pkgs/applications/graphics/pick-colour-picker/default.nix
+++ b/pkgs/applications/graphics/pick-colour-picker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 , buildPythonPackage
 , pygobject3
@@ -50,7 +50,7 @@ buildPythonPackage rec {
     sed "s|os.environ.get('SNAP'), \"usr\"|'$out'|g" -i "$pickLoc/__main__.py"
     '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://kryogenix.org/code/pick/";
     license = licenses.mit;
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/potrace/default.nix b/pkgs/applications/graphics/potrace/default.nix
index dd8e84349fad..9392f27c1713 100644
--- a/pkgs/applications/graphics/potrace/default.nix
+++ b/pkgs/applications/graphics/potrace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, zlib }:
+{ lib, stdenv, fetchurl, zlib }:
 
 stdenv.mkDerivation rec {
   pname = "potrace";
@@ -16,7 +16,7 @@ stdenv.mkDerivation rec {
   enableParallelBuilding = true;
   doCheck = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://potrace.sourceforge.net/";
     description = "A tool for tracing a bitmap, which means, transforming a bitmap into a smooth, scalable image";
     platforms = platforms.unix;
diff --git a/pkgs/applications/graphics/pqiv/default.nix b/pkgs/applications/graphics/pqiv/default.nix
index 96efc091ef2b..969a3bcb9d14 100644
--- a/pkgs/applications/graphics/pqiv/default.nix
+++ b/pkgs/applications/graphics/pqiv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, pkgconfig
+{ lib, stdenv, fetchFromGitHub, pkgconfig
 , ffmpeg_3, gtk3, imagemagick, libarchive, libspectre, libwebp, poppler
 }:
 
@@ -18,7 +18,7 @@ stdenv.mkDerivation (rec {
 
   prePatch = "patchShebangs .";
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Powerful image viewer with minimal UI";
     homepage = "http://www.pberndt.com/Programme/Linux/pqiv";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/processing/default.nix b/pkgs/applications/graphics/processing/default.nix
index de5ae4fcbfd3..434f9fab88df 100644
--- a/pkgs/applications/graphics/processing/default.nix
+++ b/pkgs/applications/graphics/processing/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, xmlstarlet, makeWrapper, ant, jdk, rsync, javaPackages, libXxf86vm, gsettings-desktop-schemas }:
+{ lib, stdenv, fetchFromGitHub, fetchurl, xmlstarlet, makeWrapper, ant, jdk, rsync, javaPackages, libXxf86vm, gsettings-desktop-schemas }:
 
 stdenv.mkDerivation rec {
   pname = "processing";
@@ -56,7 +56,7 @@ stdenv.mkDerivation rec {
         --prefix LD_LIBRARY_PATH : ${libXxf86vm}/lib
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A language and IDE for electronic arts";
     homepage = "https://processing.org";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/qcomicbook/default.nix b/pkgs/applications/graphics/qcomicbook/default.nix
index f9dc494b4b35..65ecaa90784d 100644
--- a/pkgs/applications/graphics/qcomicbook/default.nix
+++ b/pkgs/applications/graphics/qcomicbook/default.nix
@@ -1,4 +1,4 @@
-{ mkDerivation, stdenv, fetchFromGitHub, pkgconfig, cmake, qtbase, qttools, qtx11extras, poppler }:
+{ mkDerivation, lib, stdenv, fetchFromGitHub, pkgconfig, cmake, qtbase, qttools, qtx11extras, poppler }:
 
 mkDerivation rec {
   pname = "qcomicbook";
@@ -24,7 +24,7 @@ mkDerivation rec {
       --replace "Exec=qcomicbook" "Exec=$out/bin/qcomicbook"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/stolowski/QComicBook";
     description = "Comic book reader in Qt5";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/qiv/default.nix b/pkgs/applications/graphics/qiv/default.nix
index d3dd917d7b7d..e0426de6fb62 100644
--- a/pkgs/applications/graphics/qiv/default.nix
+++ b/pkgs/applications/graphics/qiv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, pkgconfig, gtk2, imlib2, file, lcms2, libexif } :
+{ lib, stdenv, fetchurl, pkgconfig, gtk2, imlib2, file, lcms2, libexif } :
 
 stdenv.mkDerivation (rec {
   version = "2.3.2";
@@ -18,7 +18,7 @@ stdenv.mkDerivation (rec {
     substituteInPlace Makefile --replace /share/share/ /share/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Quick image viewer";
     homepage = "http://spiegl.de/qiv/";
     inherit version;
diff --git a/pkgs/applications/graphics/qscreenshot/default.nix b/pkgs/applications/graphics/qscreenshot/default.nix
index 1653ea927206..635da088e560 100644
--- a/pkgs/applications/graphics/qscreenshot/default.nix
+++ b/pkgs/applications/graphics/qscreenshot/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, dos2unix, which, qt, Carbon }:
+{ lib, stdenv, fetchurl, dos2unix, which, qt, Carbon }:
 
 stdenv.mkDerivation rec {
   name = "qscreenshot-1.0";
@@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
     sed -i "s|lrelease-qt4|lrelease|" src/src.pro
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple creation and editing of screenshots";
     homepage = "https://sourceforge.net/projects/qscreenshot/";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/rapcad/default.nix b/pkgs/applications/graphics/rapcad/default.nix
index 7e9547c1067c..e86436cd06f2 100644
--- a/pkgs/applications/graphics/rapcad/default.nix
+++ b/pkgs/applications/graphics/rapcad/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, fetchurl, cgal, boost, gmp, mpfr, flex, bison, dxflib, readline
+{ lib, stdenv, fetchFromGitHub, fetchurl, cgal, boost, gmp, mpfr, flex, bison, dxflib, readline
 , qtbase, qmake, libGLU
 }:
 
@@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
   nativeBuildInputs = [ qmake ];
   buildInputs = [ qtbase cgal boost gmp mpfr flex bison dxflib readline libGLU ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.gpl3;
     maintainers = [ maintainers.raskin ];
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/rapid-photo-downloader/default.nix b/pkgs/applications/graphics/rapid-photo-downloader/default.nix
index aa6db0accdba..73341cf2ea05 100644
--- a/pkgs/applications/graphics/rapid-photo-downloader/default.nix
+++ b/pkgs/applications/graphics/rapid-photo-downloader/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, mkDerivationWith, fetchurl, python3Packages
+{ lib, stdenv, mkDerivationWith, fetchurl, python3Packages
 , file, intltool, gobject-introspection, libgudev
 , udisks, gexiv2, gst_all_1, libnotify
 , exiftool, gdk-pixbuf, libmediainfo, vmtouch
@@ -78,7 +78,7 @@ mkDerivationWith python3Packages.buildPythonApplication rec {
     )
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Photo and video importer for cameras, phones, and memory cards";
     homepage = "https://www.damonlynch.net/rapid/";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/renderdoc/default.nix b/pkgs/applications/graphics/renderdoc/default.nix
index c2edecb858f7..f9e3662f1b80 100644
--- a/pkgs/applications/graphics/renderdoc/default.nix
+++ b/pkgs/applications/graphics/renderdoc/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, cmake, pkgconfig, mkDerivation
+{ lib, stdenv, fetchFromGitHub, cmake, pkgconfig, mkDerivation
 , qtbase, qtx11extras, qtsvg, makeWrapper
 , vulkan-loader, libglvnd, xorg, python3, python3Packages
 , bison, pcre, automake, autoconf, addOpenGLRunpath
@@ -61,7 +61,7 @@ mkDerivation rec {
     addOpenGLRunpath $out/lib/librenderdoc.so
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A single-frame graphics debugger";
     homepage = "https://renderdoc.org/";
     license = licenses.mit;
diff --git a/pkgs/applications/graphics/sane/backends/generic.nix b/pkgs/applications/graphics/sane/backends/generic.nix
index d3e8b417017d..cef48daca11a 100644
--- a/pkgs/applications/graphics/sane/backends/generic.nix
+++ b/pkgs/applications/graphics/sane/backends/generic.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , gettext, pkgconfig
 , avahi, libgphoto2, libieee1284, libjpeg, libpng, libtiff, libusb1, libv4l, net-snmp
 
@@ -77,7 +77,7 @@ stdenv.mkDerivation {
     rm -f $out/etc/sane.d/net.conf
   '' + stdenv.lib.concatStrings (builtins.map installFirmware compatFirmware);
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "SANE (Scanner Access Now Easy) backends";
     longDescription = ''
       Collection of open-source SANE backends (device drivers).
diff --git a/pkgs/applications/graphics/sane/frontends.nix b/pkgs/applications/graphics/sane/frontends.nix
index 885dff311b8f..86a1f201f826 100644
--- a/pkgs/applications/graphics/sane/frontends.nix
+++ b/pkgs/applications/graphics/sane/frontends.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, sane-backends, libX11, gtk2, pkgconfig, libusb-compat-0_1 ? null }:
+{ lib, stdenv, fetchurl, sane-backends, libX11, gtk2, pkgconfig, libusb-compat-0_1 ? null }:
 
 stdenv.mkDerivation rec {
   pname = "sane-frontends";
@@ -19,7 +19,7 @@ stdenv.mkDerivation rec {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Scanner Access Now Easy";
     homepage    = "http://www.sane-project.org/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/scantailor/advanced.nix b/pkgs/applications/graphics/scantailor/advanced.nix
index e4598193469b..361f1fa18094 100644
--- a/pkgs/applications/graphics/scantailor/advanced.nix
+++ b/pkgs/applications/graphics/scantailor/advanced.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, mkDerivation
+{ lib, stdenv, fetchFromGitHub, mkDerivation
 , cmake, libjpeg, libpng, libtiff, boost
 , qtbase, qttools }:
 
@@ -16,7 +16,7 @@ mkDerivation rec {
   nativeBuildInputs = [ cmake qttools ];
   buildInputs = [ libjpeg libpng libtiff boost qtbase ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/4lex4/scantailor-advanced";
     description = "Interactive post-processing tool for scanned pages";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/shotwell/default.nix b/pkgs/applications/graphics/shotwell/default.nix
index c041d2dde8cc..992a7f787994 100644
--- a/pkgs/applications/graphics/shotwell/default.nix
+++ b/pkgs/applications/graphics/shotwell/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchurl
 , meson
 , ninja
@@ -100,7 +100,7 @@ stdenv.mkDerivation rec {
     };
   };
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Popular photo organizer for the GNOME desktop";
     homepage = "https://wiki.gnome.org/Apps/Shotwell";
     license = licenses.lgpl21Plus;
diff --git a/pkgs/applications/graphics/shutter/default.nix b/pkgs/applications/graphics/shutter/default.nix
index cddc99eebe29..2d2e332977f0 100644
--- a/pkgs/applications/graphics/shutter/default.nix
+++ b/pkgs/applications/graphics/shutter/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, perlPackages, makeWrapper, imagemagick, gdk-pixbuf, librsvg
+{ lib, stdenv, fetchurl, perlPackages, makeWrapper, imagemagick, gdk-pixbuf, librsvg
 , hicolor-icon-theme, procps
 }:
 
@@ -36,7 +36,7 @@ stdenv.mkDerivation {
       --set GDK_PIXBUF_MODULE_FILE "$GDK_PIXBUF_MODULE_FILE"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Screenshot and annotation tool";
     homepage = "https://shutter-project.org/";
     license = licenses.gpl3Plus;
diff --git a/pkgs/applications/graphics/solvespace/default.nix b/pkgs/applications/graphics/solvespace/default.nix
index 18d8d546a777..26b544cf1c5d 100644
--- a/pkgs/applications/graphics/solvespace/default.nix
+++ b/pkgs/applications/graphics/solvespace/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchgit, cmake, pkgconfig, zlib, libpng, cairo, freetype
+{ lib, stdenv, fetchgit, cmake, pkgconfig, zlib, libpng, cairo, freetype
 , json_c, fontconfig, gtkmm3, pangomm, glew, libGLU, xorg, pcre
 , wrapGAppsHook
 }:
@@ -40,7 +40,7 @@ stdenv.mkDerivation rec {
       --replace /usr/bin/ $out/bin/
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A parametric 3d CAD program";
     license = licenses.gpl3;
     maintainers = [ maintainers.edef ];
diff --git a/pkgs/applications/graphics/swingsane/default.nix b/pkgs/applications/graphics/swingsane/default.nix
index ffc19653dade..e9507129a2c0 100644
--- a/pkgs/applications/graphics/swingsane/default.nix
+++ b/pkgs/applications/graphics/swingsane/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem, unzip, jre, runtimeShell }:
+{ lib, stdenv, fetchurl, makeDesktopItem, unzip, jre, runtimeShell }:
 
 stdenv.mkDerivation rec {
   pname = "swingsane";
@@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
     cp -v -r ${desktopItem}/share/applications $out/share
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Java GUI for SANE scanner servers (saned)";
     longDescription = ''
       SwingSane is a powerful, cross platform, open source Java front-end for
diff --git a/pkgs/applications/graphics/synfigstudio/default.nix b/pkgs/applications/graphics/synfigstudio/default.nix
index e2ffd1602585..14f502434b28 100644
--- a/pkgs/applications/graphics/synfigstudio/default.nix
+++ b/pkgs/applications/graphics/synfigstudio/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, boost, cairo, gettext, glibmm, gtk3, gtkmm3
+{ lib, stdenv, fetchFromGitHub, boost, cairo, gettext, glibmm, gtk3, gtkmm3
 , libjack2, libsigcxx, libxmlxx, makeWrapper, mlt-qt5, pango, pkgconfig
 , imagemagick, intltool, autoreconfHook, which, gnome3
 }:
@@ -117,7 +117,7 @@ stdenv.mkDerivation {
 
   enableParallelBuilding = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A 2D animation program";
     homepage = "http://www.synfig.org";
     license = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/tev/default.nix b/pkgs/applications/graphics/tev/default.nix
index 2f47ebab66e4..ac8da654f057 100644
--- a/pkgs/applications/graphics/tev/default.nix
+++ b/pkgs/applications/graphics/tev/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub
+{ lib, stdenv, fetchFromGitHub
 , cmake, wrapGAppsHook
 , libX11, libzip, glfw, libpng, xorg, gnome3
 }:
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
       --prefix PATH ":" "${gnome3.zenity}/bin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "A high dynamic range (HDR) image comparison tool";
     longDescription = ''
       A high dynamic range (HDR) image comparison tool for graphics people. tev
diff --git a/pkgs/applications/graphics/timelapse-deflicker/default.nix b/pkgs/applications/graphics/timelapse-deflicker/default.nix
index ac382bb63278..f695cb2b0d76 100644
--- a/pkgs/applications/graphics/timelapse-deflicker/default.nix
+++ b/pkgs/applications/graphics/timelapse-deflicker/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, makeWrapper, perl, perlPackages }:
+{ lib, stdenv, fetchFromGitHub, makeWrapper, perl, perlPackages }:
 
 stdenv.mkDerivation rec {
   pname = "timelapse-deflicker";
@@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
     FileType ClassMethodMaker
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Simple script to deflicker images taken for timelapses";
     homepage = "https://github.com/cyberang3l/timelapse-deflicker";
     license = licenses.gpl3;
diff --git a/pkgs/applications/graphics/ufraw/default.nix b/pkgs/applications/graphics/ufraw/default.nix
index e1a0cfa95204..c30aeb15a0c2 100644
--- a/pkgs/applications/graphics/ufraw/default.nix
+++ b/pkgs/applications/graphics/ufraw/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 
 , autoconf
@@ -63,7 +63,7 @@ stdenv.mkDerivation {
     moveToOutput "lib/gimp" "$gimpPlugin"
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://github.com/sergiomb2/ufraw";
 
     broken = true; # https://github.com/NixOS/nixpkgs/issues/97946
diff --git a/pkgs/applications/graphics/viewnior/default.nix b/pkgs/applications/graphics/viewnior/default.nix
index 1addb2d7bd56..9718dee45dd8 100644
--- a/pkgs/applications/graphics/viewnior/default.nix
+++ b/pkgs/applications/graphics/viewnior/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchFromGitHub, meson, ninja, pkgconfig, desktop-file-utils, gtk2, libpng, exiv2, lcms
+{ lib, stdenv, fetchFromGitHub, meson, ninja, pkgconfig, desktop-file-utils, gtk2, libpng, exiv2, lcms
 , intltool, gettext, shared-mime-info, glib, gdk-pixbuf, perl}:
 
 stdenv.mkDerivation rec {
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     perl
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Fast and simple image viewer";
     longDescription =
       '' Viewnior is insipred by big projects like Eye of Gnome, because of it's
diff --git a/pkgs/applications/graphics/write_stylus/default.nix b/pkgs/applications/graphics/write_stylus/default.nix
index 3c2ad8f4fab0..d03c29a58ece 100644
--- a/pkgs/applications/graphics/write_stylus/default.nix
+++ b/pkgs/applications/graphics/write_stylus/default.nix
@@ -51,7 +51,7 @@ mkDerivation rec {
       $out/Write/Write
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.styluslabs.com/";
     description = "Write is a word processor for handwriting";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/xfig/default.nix b/pkgs/applications/graphics/xfig/default.nix
index fe5a13703329..3f35880b3f22 100644
--- a/pkgs/applications/graphics/xfig/default.nix
+++ b/pkgs/applications/graphics/xfig/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, xlibsWrapper, makeWrapper, libXpm
+{ lib, stdenv, fetchurl, xlibsWrapper, makeWrapper, libXpm
 , libXmu, libXi, libXp, Xaw3d, fig2dev
 }:
 
@@ -32,7 +32,7 @@ in stdenv.mkDerivation {
 
   buildInputs = [ xlibsWrapper libXpm libXmu libXi libXp Xaw3d ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "An interactive drawing tool for X11";
     longDescription = ''
       Note that you need to have the <literal>netpbm</literal> tools
diff --git a/pkgs/applications/graphics/xlife/default.nix b/pkgs/applications/graphics/xlife/default.nix
index cc7013739985..482134269d2b 100644
--- a/pkgs/applications/graphics/xlife/default.nix
+++ b/pkgs/applications/graphics/xlife/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchsvn, xorg }:
+{ lib, stdenv, fetchsvn, xorg }:
 
 stdenv.mkDerivation {
   pname = "xlife";
@@ -19,7 +19,7 @@ stdenv.mkDerivation {
     install -Dm755 lifeconv -t $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://litwr2.atspace.eu/xlife.php";
     description = "Conway's Game of Life and other cellular automata, for X";
     license = licenses.hpndSellVariant;
diff --git a/pkgs/applications/graphics/xournal/default.nix b/pkgs/applications/graphics/xournal/default.nix
index 8a5d9c3597b8..066e6cf2fb13 100644
--- a/pkgs/applications/graphics/xournal/default.nix
+++ b/pkgs/applications/graphics/xournal/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, makeDesktopItem
+{ lib, stdenv, fetchurl, makeDesktopItem
 , ghostscript, atk, gtk2, glib, fontconfig, freetype
 , libgnomecanvas, libgnomeprint, libgnomeprintui
 , pango, libX11, xorgproto, zlib, poppler
@@ -55,7 +55,7 @@ stdenv.mkDerivation rec {
       cp $out/share/xournal/pixmaps/xournal.png $out/share/icons
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://xournal.sourceforge.net/";
     description = "Note-taking application (supposes stylus)";
     maintainers = [ maintainers.guibert ];
diff --git a/pkgs/applications/graphics/xournalpp/default.nix b/pkgs/applications/graphics/xournalpp/default.nix
index c21d0ed20545..c6aa330329c2 100644
--- a/pkgs/applications/graphics/xournalpp/default.nix
+++ b/pkgs/applications/graphics/xournalpp/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitHub
 
 , cmake
@@ -50,7 +50,7 @@ stdenv.mkDerivation rec {
 
   hardeningDisable = [ "format" ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     description = "Xournal++ is a handwriting Notetaking software with PDF annotation support";
     homepage    = "https://xournalpp.github.io/";
     license     = licenses.gpl2Plus;
diff --git a/pkgs/applications/graphics/xrgears/default.nix b/pkgs/applications/graphics/xrgears/default.nix
index 33aa3ae3575e..20e01a1701da 100644
--- a/pkgs/applications/graphics/xrgears/default.nix
+++ b/pkgs/applications/graphics/xrgears/default.nix
@@ -1,4 +1,4 @@
-{ stdenv
+{ lib, stdenv
 , fetchFromGitLab
 , glm
 , glslang
@@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
     vulkan-loader
   ];
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://gitlab.freedesktop.org/monado/demos/xrgears";
     description = "An OpenXR example using Vulkan for rendering";
     platforms = platforms.linux;
diff --git a/pkgs/applications/graphics/xzgv/default.nix b/pkgs/applications/graphics/xzgv/default.nix
index 67f43faf99a3..d2c569b91c68 100644
--- a/pkgs/applications/graphics/xzgv/default.nix
+++ b/pkgs/applications/graphics/xzgv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, gtk2, libexif, pkgconfig, texinfo }:
+{ lib, stdenv, fetchurl, gtk2, libexif, pkgconfig, texinfo }:
 
 stdenv.mkDerivation rec {
   pname = "xzgv";
@@ -18,7 +18,7 @@ stdenv.mkDerivation rec {
   preInstall = ''
     mkdir -p $out/share/{app-install/desktop,applications,info,pixmaps}
   '';
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "https://sourceforge.net/projects/xzgv/";
     description = "Picture viewer for X with a thumbnail-based selector";
     license = licenses.gpl2;
diff --git a/pkgs/applications/graphics/yed/default.nix b/pkgs/applications/graphics/yed/default.nix
index d7c83704dca4..8a498fbe7ea3 100644
--- a/pkgs/applications/graphics/yed/default.nix
+++ b/pkgs/applications/graphics/yed/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchzip, makeWrapper, unzip, jre, wrapGAppsHook }:
+{ lib, stdenv, fetchzip, makeWrapper, unzip, jre, wrapGAppsHook }:
 
 stdenv.mkDerivation rec {
   pname = "yEd";
@@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
   '';
   dontWrapGApps = true;
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     license = licenses.unfree;
     homepage = "https://www.yworks.com/products/yed";
     description = "A powerful desktop application that can be used to quickly and effectively generate high-quality diagrams";
diff --git a/pkgs/applications/graphics/zgv/default.nix b/pkgs/applications/graphics/zgv/default.nix
index 6cc59a7e60bd..435f4ccaf6db 100644
--- a/pkgs/applications/graphics/zgv/default.nix
+++ b/pkgs/applications/graphics/zgv/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl, fetchpatch, pkgconfig, SDL, SDL_image, libjpeg, libpng, libtiff }:
+{ lib, stdenv, fetchurl, fetchpatch, pkgconfig, SDL, SDL_image, libjpeg, libpng, libtiff }:
 
 stdenv.mkDerivation rec {
   pname = "zgv";
@@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
     cp src/zgv $out/bin
   '';
 
-  meta = with stdenv.lib; {
+  meta = with lib; {
     homepage = "http://www.svgalib.org/rus/zgv/";
     description = "Picture viewer with a thumbnail-based selector";
     license = licenses.gpl2;